class MCollective::Agent::Discovery
Discovery agent for The Marionette Collective
Released under the Apache License, Version 2
Attributes
meta[R]
timeout[R]
Public Class Methods
new()
click to toggle source
# File lib/mcollective/agent/discovery.rb, line 9 def initialize config = Config.instance.pluginconf @timeout = 5 @meta = {:license => "Apache License, Version 2", :author => "R.I.Pienaar <rip@devco.net>", :timeout => @timeout, :name => "Discovery Agent", :version => MCollective.version, :url => "http://www.marionette-collective.org", :description => "MCollective Discovery Agent"} end
Public Instance Methods
handlemsg(msg, stomp)
click to toggle source
# File lib/mcollective/agent/discovery.rb, line 22 def handlemsg(msg, stomp) reply = "unknown request" case msg[:body] when "ping" reply = "pong" else reply = "Unknown Request: #{msg[:body]}" end reply end