CfnServiceProps Struct
Properties for defining a CfnService.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_servicediscovery as servicediscovery } from 'aws-cdk-lib';
const cfnServiceProps: servicediscovery.CfnServiceProps = {
description: 'description',
dnsConfig: {
dnsRecords: [{
ttl: 123,
type: 'type',
}],
// the properties below are optional
namespaceId: 'namespaceId',
routingPolicy: 'routingPolicy',
},
healthCheckConfig: {
type: 'type',
// the properties below are optional
failureThreshold: 123,
resourcePath: 'resourcePath',
},
healthCheckCustomConfig: {
failureThreshold: 123,
},
name: 'name',
namespaceId: 'namespaceId',
serviceAttributes: {
serviceAttributesKey: 'serviceAttributes',
},
tags: [{
key: 'key',
value: 'value',
}],
type: 'type',
};
Properties
dnsConfigIResolvable | CfnService.DnsConfigPropertydns_configtyping.Union[IResolvable, DnsConfigProperty]dnsConfigIResolvableDnsConfigIResolvableDnsConfiginterface{}#The record types of a service can only be changed by deleting the service and recreating it with a new
Dnsconfig.
healthCheckConfigIResolvable | CfnService.HealthCheckConfigPropertyhealth_check_configtyping.Union[IResolvable, HealthCheckConfigProperty]healthCheckConfigIResolvableHealthCheckConfigIResolvableHealthCheckConfiginterface{}#For information about the charges for health checks, see Amazon Route 53 Pricing .
healthCheckCustomConfigIResolvable | CfnService.HealthCheckCustomConfigPropertyhealth_check_custom_configtyping.Union[IResolvable, HealthCheckCustomConfigProperty]healthCheckCustomConfigIResolvableHealthCheckCustomConfigIResolvableHealthCheckCustomConfiginterface{}#If you specify a health check configuration, you can specify either
HealthCheckCustomConfigorHealthCheckConfigbut not both.
notes
For namespaces shared with your AWS account, specify the namespace ARN. For more information about shared namespaces, see Cross-account AWS Cloud Map namespace sharing in the AWS Cloud Map Developer Guide .
serviceAttributesIResolvable | { [key: string]: string }service_attributestyping.Union[IResolvable, typing.Mapping[str, str]]serviceAttributesIResolvableServiceAttributesIResolvableServiceAttributesinterface{}#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.
No DNS records is registered for the service instances. The only valid value is HTTP .