Class: Datadog::Core::Configuration::Components::NullCloudwise
- Inherits:
-
Object
- Object
- Datadog::Core::Configuration::Components::NullCloudwise
- Defined in:
- lib/datadog/core/configuration/components.rb
Overview
Null object pattern for when Cloudwise fails to load
Defined Under Namespace
Classes: MockProbeState
Instance Method Summary collapse
- #enabled? ⇒ Boolean
- #initialize_async(&block) ⇒ Object
- #probe_state ⇒ Object
- #start ⇒ Object
- #stop ⇒ Object
Instance Method Details
#enabled? ⇒ Boolean
112 113 114 |
# File 'lib/datadog/core/configuration/components.rb', line 112 def enabled? false end |
#initialize_async(&block) ⇒ Object
116 117 118 119 120 121 |
# File 'lib/datadog/core/configuration/components.rb', line 116 def initialize_async(&block) # If Cloudwise is disabled/failed, immediately call the callback # to allow Datadog components to initialize normally block&.call true end |
#probe_state ⇒ Object
131 132 133 134 |
# File 'lib/datadog/core/configuration/components.rb', line 131 def probe_state # Return a mock probe state that always allows collection @probe_state ||= MockProbeState.new end |
#start ⇒ Object
123 124 125 |
# File 'lib/datadog/core/configuration/components.rb', line 123 def start # No-op end |
#stop ⇒ Object
127 128 129 |
# File 'lib/datadog/core/configuration/components.rb', line 127 def stop # No-op end |