Exception: JenkinsApi::Exceptions::ServiceUnavailable

Inherits:
ApiException
  • Object
show all
Defined in:
lib/jenkins_api_client/exceptions.rb

Overview

This exception class handles cases where the Jenkins is getting restarted or reloaded where the response code returned is 503

Instance Method Summary (collapse)

Constructor Details

- (ServiceUnavailable) initialize(logger, message = "", log_level = Logger::ERROR)

Returns a new instance of ServiceUnavailable



216
217
218
219
220
221
# File 'lib/jenkins_api_client/exceptions.rb', line 216

def initialize(logger, message = "", log_level = Logger::ERROR)
  message = "Jenkins is being reloaded or restarted. Please wait till" +
    " Jenkins is completely back online. This can be" +
    " programatically achieved by System#wait_for_ready" if message.empty?
  super(logger, message)
end