Aws-cdk: support routing policy setting for ARecord class

Created on 7 Oct 2019  路  5Comments  路  Source: aws/aws-cdk

Please support routing policy parameters for ARecord in CDK.

Not all parameters are supported in CDK Route53 module currently. https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-recordset.html

any plan to support those in the future?


This is a :rocket: Feature Request

@aws-cdaws-route53 efformedium feature-request in-progress p1

Most helpful comment

Indeed, they are missing from the L2 ResourdSet construct. You can access them right now via the CfnRecordSet resource, for example:

const zone = HostedZone.fromLookup(this, 'zone', {domainName: 'example.com'});

const record = new ARecord(this, 'A', {
    zone,
    target: RecordTarget.fromIpAddresses('1.1.1.1'),
    recordName: 'www',
});

const recordSet = (record.node.defaultChild as CfnRecordSet);
recordSet.failover = 'PRIMARY';

All 5 comments

Hi @geekybaiyi,

Thank you for submitting the request! From what I could tell in the docs, it looks like all the parameters supported in Cloudformation are supported in the CDK.

Could you tell me which parameters you are missing?

how about these ?
"Failover" , "GeoLocation", "MultiValueAnswer", "Region", "SetIdentifier", "Weight"

Indeed, they are missing from the L2 ResourdSet construct. You can access them right now via the CfnRecordSet resource, for example:

const zone = HostedZone.fromLookup(this, 'zone', {domainName: 'example.com'});

const record = new ARecord(this, 'A', {
    zone,
    target: RecordTarget.fromIpAddresses('1.1.1.1'),
    recordName: 'www',
});

const recordSet = (record.node.defaultChild as CfnRecordSet);
recordSet.failover = 'PRIMARY';

I noticed an PR is created associated with this issue.
any idea when it would be merged? thx!

How can one reach CfnRecordSet from an ApplicationLoadBalancedFargateService object?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

EduardTheThird picture EduardTheThird  路  3Comments

eladb picture eladb  路  3Comments

v-do picture v-do  路  3Comments

abelmokadem picture abelmokadem  路  3Comments

artyom-melnikov picture artyom-melnikov  路  3Comments