Class: Bosh::Agent::Message::Stop
Overview
FIXME: temporary stop method
Class Method Summary collapse
Class Method Details
.long_running? ⇒ Boolean
411 412 413 |
# File 'lib/bosh_agent/handler.rb', line 411 def self.long_running? true end |
.process(args) ⇒ Object
415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 |
# File 'lib/bosh_agent/handler.rb', line 415 def self.process(args) if Config.configure Bosh::Agent::Monit.stop_services end "stopped" rescue => e # Monit retry logic should make it really hard to get here but if it happens we should yell. # One potential problem is that drain process might have unmonitored and killed processes # already but Monit became really unresponsive. In that case it might be a fake alert: # however this is not common and can be handled on case-by-case basis. raise Bosh::Agent::MessageHandlerError, "Cannot stop job: #{e}" end |