Class: AWSCDK::Autoscaling::HealthCheck Deprecated
- Inherits:
-
Jsii::Object
- Object
- Jsii::Object
- AWSCDK::Autoscaling::HealthCheck
- Defined in:
- autoscaling/health_check.rb
Overview
Deprecated.
Use HealthChecks instead
Health check settings.
Class Method Summary collapse
-
.ec2(options = nil) ⇒ AWSCDK::Autoscaling::HealthCheck
Use EC2 for health checks.
-
.elb(options) ⇒ AWSCDK::Autoscaling::HealthCheck
Use ELB for health checks.
- .jsii_overridable_methods ⇒ Object
Instance Method Summary collapse
- #grace_period ⇒ AWSCDK::Duration?
-
#initialize(*args) ⇒ HealthCheck
constructor
A new instance of HealthCheck.
- #type ⇒ String
Constructor Details
#initialize(*args) ⇒ HealthCheck
Returns a new instance of HealthCheck.
10 11 12 |
# File 'autoscaling/health_check.rb', line 10 def initialize(*args) raise NoMethodError, "aws-cdk-lib.aws_autoscaling.HealthCheck does not have a visible constructor; use the provided factory methods" end |
Class Method Details
.ec2(options = nil) ⇒ AWSCDK::Autoscaling::HealthCheck
Use EC2 for health checks.
25 26 27 28 29 |
# File 'autoscaling/health_check.rb', line 25 def self.ec2( = nil) = .is_a?(Hash) ? ::AWSCDK::Autoscaling::EC2HealthCheckOptions.new(**.transform_keys(&:to_sym)) : Jsii::Type.check_type(, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXV0b3NjYWxpbmcuRWMySGVhbHRoQ2hlY2tPcHRpb25zIn0=")), "options") unless .nil? Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_autoscaling.HealthCheck", "ec2", []) end |
.elb(options) ⇒ AWSCDK::Autoscaling::HealthCheck
Use ELB for health checks.
It considers the instance unhealthy if it fails either the EC2 status checks or the load balancer health checks.
37 38 39 40 41 |
# File 'autoscaling/health_check.rb', line 37 def self.elb() = .is_a?(Hash) ? ::AWSCDK::Autoscaling::ELBHealthCheckOptions.new(**.transform_keys(&:to_sym)) : Jsii::Type.check_type(, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXV0b3NjYWxpbmcuRWxiSGVhbHRoQ2hlY2tPcHRpb25zIn0=")), "options") Jsii::Kernel.instance.call_static("aws-cdk-lib.aws_autoscaling.HealthCheck", "elb", []) end |
.jsii_overridable_methods ⇒ Object
14 15 16 17 18 19 |
# File 'autoscaling/health_check.rb', line 14 def self.jsii_overridable_methods { :type => { kind: :property, name: "type", is_optional: false }, :grace_period => { kind: :property, name: "gracePeriod", is_optional: true }, } end |
Instance Method Details
#grace_period ⇒ AWSCDK::Duration?
49 50 51 |
# File 'autoscaling/health_check.rb', line 49 def grace_period() jsii_get_property("gracePeriod") end |
#type ⇒ String
44 45 46 |
# File 'autoscaling/health_check.rb', line 44 def type() jsii_get_property("type") end |