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

InvalidChangeBatch custom error handling no longer works #1433

Open
1 task
ewanmellor opened this issue Oct 5, 2024 · 0 comments
Open
1 task

InvalidChangeBatch custom error handling no longer works #1433

ewanmellor opened this issue Oct 5, 2024 · 0 comments
Labels
bug This issue is a bug. needs-triage This issue or PR still needs to be triaged.

Comments

@ewanmellor
Copy link

Describe the bug

Reading #242 , the error response from Route 53 used to use a custom InvalidChangeBatch element. That no longer seems to be the case: my current error response looks like this:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<ErrorResponse xmlns="https://route53.amazonaws.com/doc/2013-04-01/">
    <Error>
        <Type>Sender</Type>
        <Code>InvalidChangeBatch</Code>
        <Message>[Tried to delete resource record set [name='foo.', type='CNAME'] but it was not found]</Message>
    </Error>
    <RequestId>...</RequestId>
</ErrorResponse>

This fails to parse using the custom code here:

internal fun deserializeInvalidChangeBatchError(builder: InvalidChangeBatch.Builder, payload: ByteArray): InvalidChangeBatchErrorResponse? {

This means that the error message is lost to the caller.

Regression Issue

  • Select this option if this issue appears to be a regression.

Expected behavior

The error message from the response should be parsed into InvalidChangeBatch.message.

Current behavior

The error message is not parsed.

Steps to Reproduce

Call Route53Client.changeResourceRecordSets with invalid parameters.

Possible Solution

One change would be to extend this custom parsing to handle the <Error> tag and parse appropriately. Alternatively if someone from AWS can confirm that this endpoint has switched to the "standard" error response then maybe all this custom code can go away.

Context

Trying to parse errors from Route 53.

AWS SDK for Kotlin version

1.1.7

Platform (JVM/JS/Native)

Kotlin JVM

Operating system and version

macOS 15

@ewanmellor ewanmellor added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Oct 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. needs-triage This issue or PR still needs to be triaged.
Projects
None yet
Development

No branches or pull requests

1 participant