Class HealthCheckConfig.Builder
java.lang.Object
software.amazon.awscdk.services.servicediscovery.HealthCheckConfig.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<HealthCheckConfig>
- Enclosing interface:
HealthCheckConfig
@Stability(Stable)
public static final class HealthCheckConfig.Builder
extends Object
implements software.amazon.jsii.Builder<HealthCheckConfig>
A builder for
HealthCheckConfig
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.failureThreshold
(Number failureThreshold) Sets the value ofHealthCheckConfig.getFailureThreshold()
resourcePath
(String resourcePath) Sets the value ofHealthCheckConfig.getResourcePath()
type
(HealthCheckType type) Sets the value ofHealthCheckConfig.getType()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
failureThreshold
Sets the value ofHealthCheckConfig.getFailureThreshold()
- Parameters:
failureThreshold
- The number of consecutive health checks that an endpoint must pass or fail for Route 53 to change the current status of the endpoint from unhealthy to healthy or vice versa.- Returns:
this
-
resourcePath
Sets the value ofHealthCheckConfig.getResourcePath()
- Parameters:
resourcePath
- The path that you want Route 53 to request when performing health checks. Do not use when health check type is TCP.- Returns:
this
-
type
Sets the value ofHealthCheckConfig.getType()
- Parameters:
type
- The type of health check that you want to create, which indicates how Route 53 determines whether an endpoint is healthy. Cannot be modified once created. Supported values are HTTP, HTTPS, and TCP.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<HealthCheckConfig>
- Returns:
- a new instance of
HealthCheckConfig
- Throws:
NullPointerException
- if any required attribute was not provided
-