public void Launch() { Context.Logger.Info("[Bolt] Launch ..."); ApacheStorm.ctx = new BoltContext(); IPlugin iPlugin = this._createDelegate(ApacheStorm.ctx); if (!(iPlugin is IBolt)) { Context.Logger.Error("[Bolt] newPlugin must return IBolt!"); } this._bolt = (IBolt)iPlugin; try { //call Prepare method. this._bolt.Prepare(Context.Config, Context.TopologyContext); while (true) { StormTuple tuple = ApacheStorm.ReadTuple(); if (tuple.IsHeartBeatTuple()) { ApacheStorm.Sync(); } else { this._bolt.Execute(tuple); } } } catch (Exception ex) { Context.Logger.Error(ex.ToString()); } }
public void BeProcessesBy(IBolt bolt) { bolt.Sync(this); }
public void BeProcessesBy(IBolt bolt) { throw new System.NotImplementedException(); }
public void BeProcessesBy(IBolt bolt) { bolt.Process(this); }
public void Launch() { Context.Logger.Info("[Bolt] Launch ..."); ApacheStorm.ctx = new BoltContext(); IPlugin iPlugin = this._createDelegate(ApacheStorm.ctx); if (!(iPlugin is IBolt)) { Context.Logger.Error("[Bolt] newPlugin must return IBolt!"); } this._bolt = (IBolt)iPlugin; try { //call Prepare method. this._bolt.Prepare(Context.Config, Context.TopologyContext); while (true) { StormTuple tuple = ApacheStorm.ReadTuple(); if (tuple.IsHeartBeatTuple()) ApacheStorm.Sync(); else { this._bolt.Execute(tuple); } } } catch (Exception ex) { Context.Logger.Error(ex.ToString()); } }
public void BeProcessesBy(IBolt bolt) { _processSetup.Setup(PidDir); bolt.Initialise(this); }
public BoltExcuter(IBolt bolt, IInputs input) { this.bolt = bolt; this.input = input; this.output = new Output(); }