@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:42.138Z") @Stability(value=Stable) public class CfnService extends CfnResource implements IInspectable
A complex type that contains information about a service, which defines the configuration of the following entities:
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.servicediscovery.*;
CfnService cfnService = CfnService.Builder.create(this, "MyCfnService")
.description("description")
.dnsConfig(DnsConfigProperty.builder()
.dnsRecords(List.of(DnsRecordProperty.builder()
.ttl(123)
.type("type")
.build()))
// the properties below are optional
.namespaceId("namespaceId")
.routingPolicy("routingPolicy")
.build())
.healthCheckConfig(HealthCheckConfigProperty.builder()
.type("type")
// the properties below are optional
.failureThreshold(123)
.resourcePath("resourcePath")
.build())
.healthCheckCustomConfig(HealthCheckCustomConfigProperty.builder()
.failureThreshold(123)
.build())
.name("name")
.namespaceId("namespaceId")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.type("type")
.build();
| Modifier and Type | Class and Description |
|---|---|
static class |
CfnService.Builder
A fluent builder for
CfnService. |
static interface |
CfnService.DnsConfigProperty
A complex type that contains information about the Amazon Route 53 DNS records that you want AWS Cloud Map to create when you register an instance.
|
static interface |
CfnService.DnsRecordProperty
A complex type that contains information about the Route 53 DNS records that you want AWS Cloud Map to create when you register an instance.
|
static interface |
CfnService.HealthCheckConfigProperty
*Public DNS and HTTP namespaces only.* A complex type that contains settings for an optional health check.
|
static interface |
CfnService.HealthCheckCustomConfigProperty
A complex type that contains information about an optional custom health check.
|
software.amazon.jsii.JsiiObject.InitializationModeIInspectable.Jsii$Default, IInspectable.Jsii$Proxy| Modifier and Type | Field and Description |
|---|---|
static String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
| Modifier | Constructor and Description |
|---|---|
|
CfnService(software.constructs.Construct scope,
String id)
Create a new `AWS::ServiceDiscovery::Service`.
|
|
CfnService(software.constructs.Construct scope,
String id,
CfnServiceProps props)
Create a new `AWS::ServiceDiscovery::Service`.
|
protected |
CfnService(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnService(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
String |
getAttrArn()
The Amazon Resource Name (ARN) of the service.
|
String |
getAttrId()
The ID of the service.
|
String |
getAttrName()
The name that you assigned to the service.
|
protected Map<String,Object> |
getCfnProperties() |
String |
getDescription()
The description of the service.
|
Object |
getDnsConfig()
A complex type that contains information about the Route 53 DNS records that you want AWS Cloud Map to create when you register an instance.
|
Object |
getHealthCheckConfig()
*Public DNS and HTTP namespaces only.* A complex type that contains settings for an optional health check.
|
Object |
getHealthCheckCustomConfig()
A complex type that contains information about an optional custom health check.
|
String |
getName()
The name of the service.
|
String |
getNamespaceId()
The ID of the namespace that was used to create the service.
|
TagManager |
getTags()
The tags for the service.
|
String |
getType()
If present, specifies that the service instances are only discoverable using the `DiscoverInstances` API operation.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected Map<String,Object> |
renderProperties(Map<String,Object> props) |
void |
setDescription(String value)
The description of the service.
|
void |
setDnsConfig(CfnService.DnsConfigProperty value)
A complex type that contains information about the Route 53 DNS records that you want AWS Cloud Map to create when you register an instance.
|
void |
setDnsConfig(IResolvable value)
A complex type that contains information about the Route 53 DNS records that you want AWS Cloud Map to create when you register an instance.
|
void |
setHealthCheckConfig(CfnService.HealthCheckConfigProperty value)
*Public DNS and HTTP namespaces only.* A complex type that contains settings for an optional health check.
|
void |
setHealthCheckConfig(IResolvable value)
*Public DNS and HTTP namespaces only.* A complex type that contains settings for an optional health check.
|
void |
setHealthCheckCustomConfig(CfnService.HealthCheckCustomConfigProperty value)
A complex type that contains information about an optional custom health check.
|
void |
setHealthCheckCustomConfig(IResolvable value)
A complex type that contains information about an optional custom health check.
|
void |
setName(String value)
The name of the service.
|
void |
setNamespaceId(String value)
The ID of the namespace that was used to create the service.
|
void |
setType(String value)
If present, specifies that the service instances are only discoverable using the `DiscoverInstances` API operation.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, shouldSynthesize, toString, validatePropertiesgetRefgetCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdjsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String CFN_RESOURCE_TYPE_NAME
protected CfnService(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnService(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public CfnService(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@Nullable
CfnServiceProps props)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.props - - resource properties.@Stability(value=Stable)
public CfnService(@NotNull
software.constructs.Construct scope,
@NotNull
String id)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.@Stability(value=Stable)
public void inspect(@NotNull
TreeInspector inspector)
inspect in interface IInspectableinspector - - tree inspector to collect and process attributes. This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
renderProperties in class CfnResourceprops - This parameter is required.@Stability(value=Stable) @NotNull public String getAttrArn()
@Stability(value=Stable) @NotNull public String getAttrId()
@Stability(value=Stable) @NotNull public String getAttrName()
@Stability(value=Stable) @NotNull protected Map<String,Object> getCfnProperties()
getCfnProperties in class CfnResource@Stability(value=Stable) @NotNull public TagManager getTags()
Each tag consists of a key and an optional value, both of which you define. Tag keys can have a maximum character length of 128 characters, and tag values can have a maximum length of 256 characters.
@Stability(value=Stable) @Nullable public String getDescription()
@Stability(value=Stable)
public void setDescription(@Nullable
String value)
@Stability(value=Stable) @Nullable public Object getDnsConfig()
@Stability(value=Stable)
public void setDnsConfig(@Nullable
CfnService.DnsConfigProperty value)
@Stability(value=Stable)
public void setDnsConfig(@Nullable
IResolvable value)
@Stability(value=Stable) @Nullable public Object getHealthCheckConfig()
For information about the charges for health checks, see Amazon Route 53 Pricing .
@Stability(value=Stable)
public void setHealthCheckConfig(@Nullable
CfnService.HealthCheckConfigProperty value)
For information about the charges for health checks, see Amazon Route 53 Pricing .
@Stability(value=Stable)
public void setHealthCheckConfig(@Nullable
IResolvable value)
For information about the charges for health checks, see Amazon Route 53 Pricing .
@Stability(value=Stable) @Nullable public Object getHealthCheckCustomConfig()
If you specify a health check configuration, you can specify either
HealthCheckCustomConfigorHealthCheckConfigbut not both.
@Stability(value=Stable)
public void setHealthCheckCustomConfig(@Nullable
CfnService.HealthCheckCustomConfigProperty value)
If you specify a health check configuration, you can specify either
HealthCheckCustomConfigorHealthCheckConfigbut not both.
@Stability(value=Stable)
public void setHealthCheckCustomConfig(@Nullable
IResolvable value)
If you specify a health check configuration, you can specify either
HealthCheckCustomConfigorHealthCheckConfigbut not both.
@Stability(value=Stable) @Nullable public String getName()
@Stability(value=Stable)
public void setName(@Nullable
String value)
@Stability(value=Stable) @Nullable public String getNamespaceId()
You must specify a value for
NamespaceIdeither for the service properties or for DnsConfig . Don't specify a value in both places.
@Stability(value=Stable)
public void setNamespaceId(@Nullable
String value)
You must specify a value for
NamespaceIdeither for the service properties or for DnsConfig . Don't specify a value in both places.
@Stability(value=Stable) @Nullable public String getType()
No DNS records is registered for the service instances. The only valid value is HTTP .
@Stability(value=Stable)
public void setType(@Nullable
String value)
No DNS records is registered for the service instances. The only valid value is HTTP .
Copyright © 2022. All rights reserved.