Skip to content
This repository has been archived by the owner on Jul 30, 2022. It is now read-only.

when using scout session code multiple devices are not spawning. #3

Open
abhilashsajeev opened this issue Mar 22, 2016 · 1 comment

Comments

@abhilashsajeev
Copy link
Contributor

Only one device spawns even when you use multiple self.discover(StateMachine).

@AdamMagaluk
Copy link
Contributor

Could you provide the scout code you're using?

This is the scout i'm using, I see 3 devices created every five seconds.

var util = require('util');
var Driver = require('./driver');
var Scout = require('zetta-scout');

var CustomScout = module.exports = function() {
  Scout.call(this);
};
util.inherits(CustomScout, Scout);

CustomScout.prototype.init = function(cb) {
  var self = this;

  setInterval(function() {
    self.discover(Driver);
    self.discover(Driver);
    self.discover(Driver);
  }, 5000);

  cb();
};

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants