db_proxy_target_groups
Creates, updates, deletes or gets a db_proxy_target_group resource or lists db_proxy_target_groups in a region
Overview
| Name | db_proxy_target_groups |
| Type | Resource |
| Description | Resource schema for AWS::RDS::DBProxyTargetGroup |
| Id | awscc.rds.db_proxy_target_groups |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
db_proxy_name | string | The identifier for the proxy. |
target_group_arn | string | The Amazon Resource Name (ARN) representing the target group. |
target_group_name | string | The identifier for the DBProxyTargetGroup |
connection_pool_configuration_info | object | |
db_instance_identifiers | array | |
db_cluster_identifiers | array | |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
target_group_arn | string | The Amazon Resource Name (ARN) representing the target group. |
region | string | AWS region. |
For more information, see AWS::RDS::DBProxyTargetGroup.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | db_proxy_target_groups | INSERT | DBProxyName, TargetGroupName, region |
delete_resource | db_proxy_target_groups | DELETE | Identifier, region |
update_resource | db_proxy_target_groups | UPDATE | Identifier, PatchDocument, region |
list_resources | db_proxy_target_groups_list_only | SELECT | region |
get_resource | db_proxy_target_groups | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual db_proxy_target_group.
SELECT
region,
db_proxy_name,
target_group_arn,
target_group_name,
connection_pool_configuration_info,
db_instance_identifiers,
db_cluster_identifiers
FROM awscc.rds.db_proxy_target_groups
WHERE
region = '{{ region }}' AND
Identifier = '{{ target_group_arn }}';
Lists all db_proxy_target_groups in a region.
SELECT
region,
target_group_arn
FROM awscc.rds.db_proxy_target_groups_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new db_proxy_target_group resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.rds.db_proxy_target_groups (
DBProxyName,
TargetGroupName,
region
)
SELECT
'{{ db_proxy_name }}',
'{{ target_group_name }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.rds.db_proxy_target_groups (
DBProxyName,
TargetGroupName,
ConnectionPoolConfigurationInfo,
DBInstanceIdentifiers,
DBClusterIdentifiers,
region
)
SELECT
'{{ db_proxy_name }}',
'{{ target_group_name }}',
'{{ connection_pool_configuration_info }}',
'{{ db_instance_identifiers }}',
'{{ db_cluster_identifiers }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: db_proxy_target_group
props:
- name: db_proxy_name
value: '{{ db_proxy_name }}'
- name: target_group_name
value: '{{ target_group_name }}'
- name: connection_pool_configuration_info
value:
max_connections_percent: '{{ max_connections_percent }}'
max_idle_connections_percent: '{{ max_idle_connections_percent }}'
connection_borrow_timeout: '{{ connection_borrow_timeout }}'
session_pinning_filters:
- '{{ session_pinning_filters[0] }}'
init_query: '{{ init_query }}'
- name: db_instance_identifiers
value:
- '{{ db_instance_identifiers[0] }}'
- name: db_cluster_identifiers
value:
- '{{ db_cluster_identifiers[0] }}'
UPDATE example
Use the following StackQL query and manifest file to update a db_proxy_target_group resource, using stack-deploy.
/*+ update */
UPDATE awscc.rds.db_proxy_target_groups
SET PatchDocument = string('{{ {
"ConnectionPoolConfigurationInfo": connection_pool_configuration_info,
"DBInstanceIdentifiers": db_instance_identifiers,
"DBClusterIdentifiers": db_cluster_identifiers
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ target_group_arn }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.rds.db_proxy_target_groups
WHERE
Identifier = '{{ target_group_arn }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the db_proxy_target_groups resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
rds:DescribeDBProxies,
rds:DescribeDBProxyTargetGroups,
rds:ModifyDBProxyTargetGroup,
rds:RegisterDBProxyTargets
rds:DescribeDBProxyTargetGroups,
rds:DescribeDBProxyTargets
rds:DescribeDBProxyTargetGroups,
rds:ModifyDBProxyTargetGroup,
rds:RegisterDBProxyTargets,
rds:DeregisterDBProxyTargets
rds:DeregisterDBProxyTargets
rds:DescribeDBProxyTargetGroups