Class: Google::Apis::RunV1::Probe
- Inherits:
-
Object
- Object
- Google::Apis::RunV1::Probe
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/run_v1/classes.rb,
lib/google/apis/run_v1/representations.rb,
lib/google/apis/run_v1/representations.rb
Overview
Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic.
Instance Attribute Summary collapse
-
#exec ⇒ Google::Apis::RunV1::ExecAction
Not supported by Cloud Run.
-
#failure_threshold ⇒ Fixnum
Minimum consecutive failures for the probe to be considered failed after having succeeded.
-
#grpc ⇒ Google::Apis::RunV1::GrpcAction
GRPCAction describes an action involving a GRPC port.
-
#http_get ⇒ Google::Apis::RunV1::HttpGetAction
HTTPGetAction describes an action based on HTTP Get requests.
-
#initial_delay_seconds ⇒ Fixnum
Number of seconds after the container has started before the probe is initiated.
-
#period_seconds ⇒ Fixnum
How often (in seconds) to perform the probe.
-
#success_threshold ⇒ Fixnum
Minimum consecutive successes for the probe to be considered successful after having failed.
-
#tcp_socket ⇒ Google::Apis::RunV1::TcpSocketAction
TCPSocketAction describes an action based on opening a socket Corresponds to the JSON property
tcpSocket
. -
#timeout_seconds ⇒ Fixnum
Number of seconds after which the probe times out.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Probe
constructor
A new instance of Probe.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Probe
Returns a new instance of Probe.
2499 2500 2501 |
# File 'lib/google/apis/run_v1/classes.rb', line 2499 def initialize(**args) update!(**args) end |
Instance Attribute Details
#exec ⇒ Google::Apis::RunV1::ExecAction
Not supported by Cloud Run. ExecAction describes a "run in container" action.
Corresponds to the JSON property exec
2449 2450 2451 |
# File 'lib/google/apis/run_v1/classes.rb', line 2449 def exec @exec end |
#failure_threshold ⇒ Fixnum
Minimum consecutive failures for the probe to be considered failed after
having succeeded. Defaults to 3. Minimum value is 1.
Corresponds to the JSON property failureThreshold
2455 2456 2457 |
# File 'lib/google/apis/run_v1/classes.rb', line 2455 def failure_threshold @failure_threshold end |
#grpc ⇒ Google::Apis::RunV1::GrpcAction
GRPCAction describes an action involving a GRPC port.
Corresponds to the JSON property grpc
2460 2461 2462 |
# File 'lib/google/apis/run_v1/classes.rb', line 2460 def grpc @grpc end |
#http_get ⇒ Google::Apis::RunV1::HttpGetAction
HTTPGetAction describes an action based on HTTP Get requests.
Corresponds to the JSON property httpGet
2465 2466 2467 |
# File 'lib/google/apis/run_v1/classes.rb', line 2465 def http_get @http_get end |
#initial_delay_seconds ⇒ Fixnum
Number of seconds after the container has started before the probe is
initiated. Defaults to 0 seconds. Minimum value is 0. Maximum value for
liveness probe is 3600. Maximum value for startup probe is 240.
Corresponds to the JSON property initialDelaySeconds
2472 2473 2474 |
# File 'lib/google/apis/run_v1/classes.rb', line 2472 def initial_delay_seconds @initial_delay_seconds end |
#period_seconds ⇒ Fixnum
How often (in seconds) to perform the probe. Default to 10 seconds. Minimum
value is 1. Maximum value for liveness probe is 3600. Maximum value for
startup probe is 240. Must be greater or equal than timeout_seconds.
Corresponds to the JSON property periodSeconds
2479 2480 2481 |
# File 'lib/google/apis/run_v1/classes.rb', line 2479 def period_seconds @period_seconds end |
#success_threshold ⇒ Fixnum
Minimum consecutive successes for the probe to be considered successful after
having failed. Must be 1 if set.
Corresponds to the JSON property successThreshold
2485 2486 2487 |
# File 'lib/google/apis/run_v1/classes.rb', line 2485 def success_threshold @success_threshold end |
#tcp_socket ⇒ Google::Apis::RunV1::TcpSocketAction
TCPSocketAction describes an action based on opening a socket
Corresponds to the JSON property tcpSocket
2490 2491 2492 |
# File 'lib/google/apis/run_v1/classes.rb', line 2490 def tcp_socket @tcp_socket end |
#timeout_seconds ⇒ Fixnum
Number of seconds after which the probe times out. Defaults to 1 second.
Minimum value is 1. Maximum value is 3600. Must be smaller than period_seconds;
if period_seconds is not set, must be less or equal than 10.
Corresponds to the JSON property timeoutSeconds
2497 2498 2499 |
# File 'lib/google/apis/run_v1/classes.rb', line 2497 def timeout_seconds @timeout_seconds end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 |
# File 'lib/google/apis/run_v1/classes.rb', line 2504 def update!(**args) @exec = args[:exec] if args.key?(:exec) @failure_threshold = args[:failure_threshold] if args.key?(:failure_threshold) @grpc = args[:grpc] if args.key?(:grpc) @http_get = args[:http_get] if args.key?(:http_get) @initial_delay_seconds = args[:initial_delay_seconds] if args.key?(:initial_delay_seconds) @period_seconds = args[:period_seconds] if args.key?(:period_seconds) @success_threshold = args[:success_threshold] if args.key?(:success_threshold) @tcp_socket = args[:tcp_socket] if args.key?(:tcp_socket) @timeout_seconds = args[:timeout_seconds] if args.key?(:timeout_seconds) end |