aws-cloudformation / aws-cloudformation/cloudformation-coverage-roadmap

[AWS::RDS::DBProxyTargetGroup] - [BUG] - CloudControl GetResource fails

Open
#2,132 2 comments 2 reactions 0 assignees View on GitHub
bug
Dominant language
No language data
Stars
1.1k
Forks
62
PR merge metrics
No merged PRs in 30d

Description

### Name of the resource

AWS::RDS::DBProxyTargetGroup

### Resource Name

_No response_

### Issue Description

When making a CloudControl `GetResource` request for a `DBProxyTargetGroup` it fails with the below error

```
An error occurred (GeneralServiceException) when calling the GetResource operation: AWS::RDS::DBProxyTargetGroup Handler returned status FAILED: 1 validation error detected: Value null at 'dBProxyName' failed to satisfy constraint: Member must not be null (Service: AmazonRDS; Status Code: 400; Error Code: ValidationError
```

### Expected Behavior

`GetResource returns successfully.

### Observed Behavior

Fails with above error message.

### Test Cases

Create a DBProxyTargetGroup and then:

```yml
Parameters:
RDSDBSubnetGroup00pyormsqllchemydbe14e100cxLuPSubnetIds2pG6r:
NoEcho: "true"
Type: "CommaDelimitedList"
Description: "The EC2 Subnet IDs for the DB subnet group."
Resources:
EC2Subnet00subnet09a5a61e428c3924d002H8ef:
UpdateReplacePolicy: "Retain"
Type: "AWS::EC2::Subnet"
DeletionPolicy: "Retain"
Properties:
VpcId:
Ref: "EC2VPC00vpc069539751ab5b5210005nbbM"
CidrBlock: "10.0.128.0/18"
SecretsManagerSecret00secretdbCredentialNxo7M700Y6DVj:
UpdateReplacePolicy: "Retain"
Type: "AWS::SecretsManager::Secret"
DeletionPolicy: "Retain"
Properties:
ReplicaRegions: []
Tags: []
Name: "dbCredential"
RDSDBProxy00pyormsqllchemy5c20a1800Io7mA:
UpdateReplacePolicy: "Retain"
Type: "AWS::RDS::DBProxy"
DeletionPolicy: "Retain"
Properties:
RequireTLS: false
DBProxyName: "py-orm-sqllchemy-5c20a18"
IdleClientTimeout: 1800
VpcSecurityGroupIds:
- Fn::GetAtt:
- "EC2SecurityGroup00sg0d70c1b44b2889eca009oenv"
- "GroupId"
Auth:
- SecretArn:
Ref: "SecretsManagerSecret00secretdbCredentialNxo7M700Y6DVj"
IAMAuth: "DISABLED"
ClientPasswordAuthType: "POSTGRES_SCRAM_SHA_256"
AuthScheme: "SECRETS"
DebugLogging: false
VpcSubnetIds:
- Ref: "EC2Subnet00subnet04d12c7ef812fa0c2005dngh"
- Ref: "EC2Subnet00subnet09a5a61e428c3924d002H8ef"
EngineFamily: "POSTGRESQL"
RoleArn:
Fn::GetAtt:
- "IAMRole00dbProxyRole98e180600KaqOm"
- "Arn"
EC2Subnet00subnet04d12c7ef812fa0c2005dngh:
UpdateReplacePolicy: "Retain"
Type: "AWS::EC2::Subnet"
DeletionPolicy: "Retain"
Properties:
VpcId:
Ref: "EC2VPC00vpc069539751ab5b5210005nbbM"
CidrBlock: "10.0.192.0/18"
EC2SecurityGroup00sg0d70c1b44b2889eca009oenv:
UpdateReplacePolicy: "Retain"
Type: "AWS::EC2::SecurityGroup"
DeletionPolicy: "Retain"
Properties:
GroupDescription: "default VPC security group"
GroupName: "default"
VpcId:
Ref: "EC2VPC00vpc069539751ab5b5210005nbbM"
SecurityGroupIngress:
- IpProtocol: "-1"
FromPort: -1
SourceSecurityGroupId:
Fn::GetAtt:
- "EC2VPC00vpc069539751ab5b5210005nbbM"
- "DefaultSecurityGroup"
ToPort: -1
SourceSecurityGroupOwnerId: "616138583583"
SecurityGroupEgress:
- CidrIp: "0.0.0.0/0"
IpProtocol: "-1"
FromPort: -1
ToPort: -1
RDSDBInstance00pyormsqllchemy4763a0000QMGcW:
UpdateReplacePolicy: "Retain"
Type: "AWS::RDS::DBInstance"
DeletionPolicy: "Retain"
Properties:
Engine: "postgres"
EngineVersion: "16.1"
DBInstanceClass: "db.t4g.micro"
AvailabilityZone: "us-east-2b"
AutoMinorVersionUpgrade: true
DBSubnetGroupName:
Ref: "RDSDBSubnetGroup00pyormsqllchemydbe14e100cxLuP"
DBInstanceIdentifier: "py-orm-sql-lchemy4763a00"
AllocatedStorage: "20"
VPCSecurityGroups:
- Fn::GetAtt:
- "EC2SecurityGroup00sg0d70c1b44b2889eca009oenv"
- "GroupId"
MasterUsername: "db_user"
DBName: "sqlAlchemy"
EnableIAMDatabaseAuthentication: true
IAMRole00dbProxyRole98e180600KaqOm:
UpdateReplacePolicy: "Retain"
Type: "AWS::IAM::Role"
DeletionPolicy: "Retain"
Properties:
Path: "/"
MaxSessionDuration: 3600
RoleName: "dbProxyRole-98e1806"
AssumeRolePolicyDocument:
Version: "2012-10-17"
Statement:
- Action: "sts:AssumeRole"
Effect: "Allow"
Principal:
Service: "rds.amazonaws.com"
Sid: "AllowAssumeRole"
EC2VPC00vpc069539751ab5b5210005nbbM:
UpdateReplacePolicy: "Retain"
Type: "AWS::EC2::VPC"
DeletionPolicy: "Retain"
Properties:
CidrBlock: "10.0.0.0/16"
EnableDnsSupport: true
InstanceTenancy: "default"
EnableDnsHostnames: true
Tags:
- Value: "chall-stack/chall-vpc"
Key: "Name"
RDSDBSubnetGroup00pyormsqllchemydbe14e100cxLuP:
UpdateReplacePolicy: "Retain"
Type: "AWS::RDS::DBSubnetGroup"
DeletionPolicy: "Retain"
Properties:
SubnetIds:
Ref: "RDSDBSubnetGroup00pyormsqllchemydbe14e100cxLuPSubnetIds2pG6r"
DBSubnetGroupDescription: "Managed by Pulumi"
DBSubnetGroupName: "py-orm-sqllchemy-dbe14e1"
DBProxyTargetGroup:
Type: "AWS::RDS::DBProxyTargetGroup"
Properties:
DBProxyName: !Ref RDSDBProxy00pyormsqllchemy5c20a1800Io7mA
DBInstanceIdentifiers: [!Ref RDSDBInstance00pyormsqllchemy4763a0000QMGcW]
TargetGroupName: default
ConnectionPoolConfigurationInfo:
MaxConnectionsPercent: 100
MaxIdleConnectionsPercent: 50
ConnectionBorrowTimeout: 120
```

```
aws cloudcontrol get-resource --type-name AWS::RDS::DBProxyTargetGroup --identifier INSERT_IDENTIFIER
```

### Other Details

Reported in https://github.com/pulumi/pulumi-aws-native/issues/872

Contributor guide

Open the contributing guide

Research direction

Reproduce the failure using CloudControl GetResource for AWS::RDS::DBProxyTargetGroup and the supplied CloudFormation template, then inspect the resource's GetResource entry point. Trace why dBProxyName is null in the Amazon RDS request; done means the same CLI request returns the resource successfully without the validation error.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, postgresql
Domain
cloud, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.