Skip to main content

traffic_policy_instances_by_policies

Creates, updates, deletes, gets or lists a traffic_policy_instances_by_policies resource.

Overview

Nametraffic_policy_instances_by_policies
TypeResource
Idaws.route53.traffic_policy_instances_by_policies

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
hosted_zone_idstringThe ID of the hosted zone that Amazon Route 53 created resource record sets in.
idstringThe ID that Amazon Route 53 assigned to the new traffic policy instance.
messagestringIf State is Failed, an explanation of the reason for the failure. If State is another value, Message is empty.
namestringThe DNS name, such as www.example.com, for which Amazon Route 53 responds to queries by using the resource record sets that are associated with this traffic policy instance.
statestringThe value of State is one of the following values: Applied Amazon Route 53 has finished creating resource record sets, and changes have propagated to all Route 53 edge locations. Creating Route 53 is creating the resource record sets. Use GetTrafficPolicyInstance to confirm that the CreateTrafficPolicyInstance request completed successfully. Failed Route 53 wasn't able to create or update the resource record sets. When the value of State is Failed, see Message for an explanation of what caused the request to fail.
ttlintegerThe TTL that Amazon Route 53 assigned to all of the resource record sets that it created in the specified hosted zone.
traffic_policy_idstringThe ID of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.
traffic_policy_typestringThe DNS type that Amazon Route 53 assigned to all of the resource record sets that it created for this traffic policy instance.
traffic_policy_versionintegerThe version of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_traffic_policy_instances_by_policyselectid, version, regionhostedzoneid, trafficpolicyinstancename, trafficpolicyinstancetype, maxitemsGets information about the traffic policy instances that you created by using a specify traffic policy version. After you submit a CreateTrafficPolicyInstance or an UpdateTrafficPolicyInstance request, there's a brief delay while Amazon Route 53 creates the resource record sets that are specified in the traffic policy definition. For more information, see the State response element. Route 53 returns a maximum of 100 items in each response. If you have a lot of traffic policy instances, you can use the MaxItems parameter to list them in groups of up to 100.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
idstringThe ID of the traffic policy for which you want to list traffic policy instances.
regionstringAWS region (default: us-east-1)
versionintegerThe version of the traffic policy for which you want to list traffic policy instances. The version must be associated with the traffic policy that is specified by TrafficPolicyId.
hostedzoneidstringIf the value of IsTruncated in the previous response was true, you have more traffic policy instances. To get more traffic policy instances, submit another ListTrafficPolicyInstancesByPolicy request. For the value of hostedzoneid, specify the value of HostedZoneIdMarker from the previous response, which is the hosted zone ID of the first traffic policy instance that Amazon Route 53 will return if you submit another request. If the value of IsTruncated in the previous response was false, there are no more traffic policy instances to get.
maxitemsstringThe maximum number of traffic policy instances to be included in the response body for this request. If you have more than MaxItems traffic policy instances, the value of the IsTruncated element in the response is true, and the values of HostedZoneIdMarker, TrafficPolicyInstanceNameMarker, and TrafficPolicyInstanceTypeMarker represent the first traffic policy instance that Amazon Route 53 will return if you submit another request.
trafficpolicyinstancenamestringIf the value of IsTruncated in the previous response was true, you have more traffic policy instances. To get more traffic policy instances, submit another ListTrafficPolicyInstancesByPolicy request. For the value of trafficpolicyinstancename, specify the value of TrafficPolicyInstanceNameMarker from the previous response, which is the name of the first traffic policy instance that Amazon Route 53 will return if you submit another request. If the value of IsTruncated in the previous response was false, there are no more traffic policy instances to get.
trafficpolicyinstancetypestringIf the value of IsTruncated in the previous response was true, you have more traffic policy instances. To get more traffic policy instances, submit another ListTrafficPolicyInstancesByPolicy request. For the value of trafficpolicyinstancetype, specify the value of TrafficPolicyInstanceTypeMarker from the previous response, which is the name of the first traffic policy instance that Amazon Route 53 will return if you submit another request. If the value of IsTruncated in the previous response was false, there are no more traffic policy instances to get.

SELECT examples

Gets information about the traffic policy instances that you created by using a specify traffic policy version. After you submit a CreateTrafficPolicyInstance or an UpdateTrafficPolicyInstance request, there's a brief delay while Amazon Route 53 creates the resource record sets that are specified in the traffic policy definition. For more information, see the State response element. Route 53 returns a maximum of 100 items in each response. If you have a lot of traffic policy instances, you can use the MaxItems parameter to list them in groups of up to 100.

SELECT
hosted_zone_id,
id,
message,
name,
state,
ttl,
traffic_policy_id,
traffic_policy_type,
traffic_policy_version
FROM aws.route53.traffic_policy_instances_by_policies
WHERE id = '{{ id }}' -- required
AND version = '{{ version }}' -- required
AND region = '{{ region }}' -- required
AND hostedzoneid = '{{ hostedzoneid }}'
AND trafficpolicyinstancename = '{{ trafficpolicyinstancename }}'
AND trafficpolicyinstancetype = '{{ trafficpolicyinstancetype }}'
AND maxitems = '{{ maxitems }}'
;