Class: Droonga::Plugins::System::StatusHandler
- Defined in:
- lib/droonga/plugins/system.rb
Instance Attribute Summary
Attributes inherited from Handler
Instance Method Summary collapse
Methods inherited from Handler
Methods included from Droonga::Pluggable
Constructor Details
This class inherits a constructor from Droonga::Handler
Instance Method Details
#handle(message) ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/droonga/plugins/system.rb', line 27 def handle() engine_state = @messenger.engine_state live_nodes = engine_state.live_nodes nodes = {} engine_state.all_nodes.collect do |identifier| nodes[identifier] = { "live" => live_nodes.include?(identifier), } end { "nodes" => nodes, } end |