Class: AWSCDK::AppMesh::HttpHealthCheckOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::AppMesh::HttpHealthCheckOptions
- Defined in:
- app_mesh/http_health_check_options.rb
Overview
Properties used to define HTTP Based healthchecks.
Instance Attribute Summary collapse
-
#healthy_threshold ⇒ Numeric?
readonly
The number of consecutive successful health checks that must occur before declaring listener healthy.
-
#interval ⇒ AWSCDK::Duration?
readonly
The time period between each health check execution.
-
#path ⇒ String?
readonly
The destination path for the health check request.
-
#timeout ⇒ AWSCDK::Duration?
readonly
The amount of time to wait when receiving a response from the health check.
-
#unhealthy_threshold ⇒ Numeric?
readonly
The number of consecutive failed health checks that must occur before declaring a listener unhealthy.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(healthy_threshold: nil, interval: nil, path: nil, timeout: nil, unhealthy_threshold: nil) ⇒ HttpHealthCheckOptions
constructor
A new instance of HttpHealthCheckOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(healthy_threshold: nil, interval: nil, path: nil, timeout: nil, unhealthy_threshold: nil) ⇒ HttpHealthCheckOptions
Returns a new instance of HttpHealthCheckOptions.
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'app_mesh/http_health_check_options.rb', line 12 def initialize(healthy_threshold: nil, interval: nil, path: nil, timeout: nil, unhealthy_threshold: nil) @healthy_threshold = healthy_threshold Jsii::Type.check_type(@healthy_threshold, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "healthyThreshold") unless @healthy_threshold.nil? @interval = interval Jsii::Type.check_type(@interval, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5EdXJhdGlvbiJ9")), "interval") unless @interval.nil? @path = path Jsii::Type.check_type(@path, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "path") unless @path.nil? @timeout = timeout Jsii::Type.check_type(@timeout, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5EdXJhdGlvbiJ9")), "timeout") unless @timeout.nil? @unhealthy_threshold = unhealthy_threshold Jsii::Type.check_type(@unhealthy_threshold, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "unhealthyThreshold") unless @unhealthy_threshold.nil? end |
Instance Attribute Details
#healthy_threshold ⇒ Numeric? (readonly)
Default: 2
The number of consecutive successful health checks that must occur before declaring listener healthy.
29 30 31 |
# File 'app_mesh/http_health_check_options.rb', line 29 def healthy_threshold @healthy_threshold end |
#interval ⇒ AWSCDK::Duration? (readonly)
Default: Duration.seconds(5)
The time period between each health check execution.
34 35 36 |
# File 'app_mesh/http_health_check_options.rb', line 34 def interval @interval end |
#path ⇒ String? (readonly)
Default: /
The destination path for the health check request.
39 40 41 |
# File 'app_mesh/http_health_check_options.rb', line 39 def path @path end |
#timeout ⇒ AWSCDK::Duration? (readonly)
Default: Duration.seconds(2)
The amount of time to wait when receiving a response from the health check.
44 45 46 |
# File 'app_mesh/http_health_check_options.rb', line 44 def timeout @timeout end |
#unhealthy_threshold ⇒ Numeric? (readonly)
Default: - 2
The number of consecutive failed health checks that must occur before declaring a listener unhealthy.
49 50 51 |
# File 'app_mesh/http_health_check_options.rb', line 49 def unhealthy_threshold @unhealthy_threshold end |
Class Method Details
.jsii_properties ⇒ Object
51 52 53 54 55 56 57 58 59 |
# File 'app_mesh/http_health_check_options.rb', line 51 def self.jsii_properties { :healthy_threshold => "healthyThreshold", :interval => "interval", :path => "path", :timeout => "timeout", :unhealthy_threshold => "unhealthyThreshold", } end |
Instance Method Details
#to_jsii ⇒ Object
61 62 63 64 65 66 67 68 69 70 71 |
# File 'app_mesh/http_health_check_options.rb', line 61 def to_jsii result = {} result.merge!({ "healthyThreshold" => @healthy_threshold, "interval" => @interval, "path" => @path, "timeout" => @timeout, "unhealthyThreshold" => @unhealthy_threshold, }) result.compact end |