Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backup update_regions_settings doesnt support all services #3758

Closed
CXmartins opened this issue Jun 22, 2023 · 2 comments
Closed

Backup update_regions_settings doesnt support all services #3758

CXmartins opened this issue Jun 22, 2023 · 2 comments
Assignees
Labels
backup bug This issue is a confirmed bug. p3 This is a minor priority issue response-requested Waiting on additional information or feedback.

Comments

@CXmartins
Copy link

Describe the bug

boto3 client.update_regions_settings on backup client doesn't support all service type available on describe_regions_settings, foe example neptune or redshift.
Doing the same using aws cli works fine.

Example code:
backup_client = boto3.client("backup")
backup_client.update_region_settings(
ResourceTypeOptInPreference={"Neptune": False}
)

Throws:
botocore.errorfactory.InvalidParameterValueException: An error occurred (InvalidParameterValueException) when calling the UpdateRegionSettings operation: Element present in resource type opt in preference has invalid values. Please use describeRegionSettings API to know the supported resource types

Example of describe_region_settings:
{'ResponseMetadata': {'RequestId': '0699bf20-0b8b-486b-96e5-59416499cf54', 'HTTPStatusCode': 200, 'HTTPHeaders': {'date': 'Thu, 22 Jun 2023 15:16:08 GMT', 'content-type': 'application/json', 'content-length': '345', 'connection': 'keep-alive', 'x-amzn-requestid': '0699bf20-0b8b-486b-96e5-59416499cf54'}, 'RetryAttempts': 0}, 'ResourceTypeOptInPreference': {'Aurora': False, 'CloudFormation': False, 'DocumentDB': False, 'DynamoDB': True, 'EBS': True, 'EC2': True, 'EFS': True, 'FSx': False, 'Neptune': False, 'RDS': True, 'Redshift': True, 'S3': True, 'SAP HANA on Amazon EC2': False, 'Storage Gateway': True, 'VirtualMachine': False}, 'ResourceTypeManagementPreference': {'DynamoDB': True, 'EFS': True}}

Expected Behavior

That it accepts all AWS Backup services

Current Behavior

Example code:
backup_client = boto3.client("backup")
backup_client.update_region_settings(
ResourceTypeOptInPreference={"Neptune": False}
)

Throws:
botocore.errorfactory.InvalidParameterValueException: An error occurred (InvalidParameterValueException) when calling the UpdateRegionSettings operation: Element present in resource type opt in preference has invalid values. Please use describeRegionSettings API to know the supported resource types

Reproduction Steps

backup_client = boto3.client("backup")
backup_client.update_region_settings(
ResourceTypeOptInPreference={"Neptune": False}
)

Possible Solution

No response

Additional Information/Context

No response

SDK version used

python3.9 - boto3 1.26.158

Environment details (OS name and version, etc.)

windows 10

@CXmartins CXmartins added bug This issue is a confirmed bug. needs-triage This issue or PR still needs to be triaged. labels Jun 22, 2023
@RyanFitzSimmonsAK RyanFitzSimmonsAK self-assigned this Jun 22, 2023
@RyanFitzSimmonsAK RyanFitzSimmonsAK added p3 This is a minor priority issue backup investigating This issue is being investigated and/or work is in progress to resolve the issue. and removed needs-triage This issue or PR still needs to be triaged. labels Jun 22, 2023
@RyanFitzSimmonsAK
Copy link
Contributor

Hi @CXmartins, thanks for reaching out. I had some trouble reproducing this behavior; I was able to update my preferences using the reproduction code you provided. Could you provide debug logs of this behavior? You can get debug logs by adding boto3.set_stream_logger('') to your script, and redacting any sensitive information. Thanks!

@RyanFitzSimmonsAK RyanFitzSimmonsAK added response-requested Waiting on additional information or feedback. and removed bug This issue is a confirmed bug. investigating This issue is being investigated and/or work is in progress to resolve the issue. labels Jun 22, 2023
@CXmartins
Copy link
Author

Hey, just figured it out. I was deploying to a region that didnt have neptune available on the backup. Sorry for wasting your time and thank you for the support
Closing this one

@RyanFitzSimmonsAK RyanFitzSimmonsAK added the bug This issue is a confirmed bug. label Nov 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backup bug This issue is a confirmed bug. p3 This is a minor priority issue response-requested Waiting on additional information or feedback.
Projects
None yet
Development

No branches or pull requests

2 participants