Exception: Google::Cloud::Env::MetadataServerNotResponding

Inherits:
StandardError
  • Object
show all
Defined in:
lib/google/cloud/env/compute_metadata.rb

Overview

Error raised when the compute metadata server is expected to be present in the current environment, but couldn't be contacted.

Constant Summary collapse

DEFAULT_MESSAGE =

Default message for the error

Returns:

  • (String)
"The Google Metadata Server did not respond to queries. This " \
"could be because no Server is present, the Server has not yet " \
"finished starting up, the Server is running but overloaded, or " \
"Server could not be contacted due to networking issues."

Instance Method Summary collapse

Constructor Details

#initialize(message = nil) ⇒ MetadataServerNotResponding

Create a new MetadataServerNotResponding.

Parameters:

  • message (String) (defaults to: nil)

    Error message. If not provided, defaults to DEFAULT_MESSAGE.



876
877
878
879
# File 'lib/google/cloud/env/compute_metadata.rb', line 876

def initialize message = nil
  message ||= DEFAULT_MESSAGE
  super message
end