seneca-balance-client icon indicating copy to clipboard operation
seneca-balance-client copied to clipboard

adding same pattern more than once causes stack overflow

Open rjrodger opened this issue 7 years ago • 2 comments

rjrodger avatar Mar 06 '17 16:03 rjrodger

var Seneca = require('seneca')

Seneca()
  .listen(47000)
  .add('a:1', function (msg, done) {
    done( null, {a: 1, x: msg.x} )
  })
  .ready(function() {
  
    Seneca()
      .listen(47001)
      .add('a:1', function (msg, done) {
        done( null, {a: 2, x: msg.x} )
      })
      .ready(function() {

        Seneca()
          .use('../')
          .client( {pin: 'a:1', type: 'balance'} )
          .client( {pin: 'a:1', type: 'balance'} )
          .client( {pin: 'a:1', port: 47000} )
          .client( {pin: 'a:1', port: 47001} )

          .act('a:1', console.log)

      })
  })

rjrodger avatar Mar 06 '17 16:03 rjrodger

@rjrodger what the use case of the above?

MikeLindenau avatar Mar 22 '19 22:03 MikeLindenau