Skip to content

Expose the extendedRequestId from SdkServiceException #1798

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

Merged
merged 2 commits into from
May 14, 2020
Merged

Expose the extendedRequestId from SdkServiceException #1798

merged 2 commits into from
May 14, 2020

Conversation

Sarev0k
Copy link
Contributor

@Sarev0k Sarev0k commented Apr 29, 2020

Description

Adds a new extendedRequestId property to the SdkServiceException class and includes it in the contents of AwsServiceException messages.

Motivation and Context

Currently the only way to access this information from the exception is via the headers supplied by the SdkHttpResponse in the exception's errorDetails. However when the AWS client is automatically retrying and causing my Lambda function to timeout due to the added time it takes to retry, I have no way to access this information. AWS support requires this information in order to deep dive issues for some services such as S3.

Testing

Ran mvn clean install and the build succeeded.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have read the CONTRIBUTING document
  • Local run of mvn install succeeds
  • My code follows the code style of this project
  • My change requires a change to the Javadoc documentation
  • I have updated the Javadoc documentation accordingly
  • I have read the README document
  • I have added tests to cover my changes
  • All new and existing tests passed
  • A short description of the change has been added to the CHANGELOG
  • My change is to implement 1.11 parity feature and I have updated LaunchChangelog

License

  • I confirm that this pull request can be released under the Apache 2 license

@Sarev0k Sarev0k changed the title Add the extendedRequestId to the SdkServiceException message Add the extendedRequestId to the AwsServiceException message Apr 29, 2020
@Sarev0k
Copy link
Contributor Author

Sarev0k commented May 10, 2020

Hey @millems, could you please take a look at this?

Thanks.

@Sarev0k Sarev0k changed the title Add the extendedRequestId to the AwsServiceException message Expose the extendedRequestId from SdkServiceException May 13, 2020
@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 0 Code Smells

75.0% 75.0% Coverage
7.1% 7.1% Duplication

@codecov-io
Copy link

codecov-io commented May 13, 2020

Codecov Report

Merging #1798 into master will decrease coverage by 0.02%.
The diff coverage is 75.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1798      +/-   ##
============================================
- Coverage     76.29%   76.27%   -0.03%     
  Complexity      187      187              
============================================
  Files          1074     1074              
  Lines         32450    32469      +19     
  Branches       2550     2550              
============================================
+ Hits          24759    24767       +8     
- Misses         6438     6446       +8     
- Partials       1253     1256       +3     
Flag Coverage Δ Complexity Δ
#unittests 76.27% <75.00%> (-0.03%) 187.00 <0.00> (ø)
Impacted Files Coverage Δ Complexity Δ
...zon/awssdk/core/exception/SdkServiceException.java 60.00% <44.44%> (-3.89%) 0.00 <0.00> (ø)
.../awssdk/awscore/exception/AwsServiceException.java 75.43% <100.00%> (+1.36%) 0.00 <0.00> (ø)
...l/unmarshall/AwsJsonProtocolErrorUnmarshaller.java 98.27% <100.00%> (+0.06%) 0.00 <0.00> (ø)
.../json/internal/unmarshall/JsonResponseHandler.java 95.45% <100.00%> (+0.71%) 0.00 <0.00> (ø)
...y/internal/unmarshall/AwsXmlErrorUnmarshaller.java 98.21% <100.00%> (+0.06%) 0.00 <0.00> (ø)
...nio/netty/internal/OldConnectionReaperHandler.java 81.81% <0.00%> (-9.10%) 0.00% <0.00%> (ø%)
...ssdk/core/internal/async/FileAsyncRequestBody.java 84.76% <0.00%> (-2.86%) 0.00% <0.00%> (ø%)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update abab62e...6fb8287. Read the comment docs.

@millems millems merged commit 63af4df into aws:master May 14, 2020
aws-sdk-java-automation added a commit that referenced this pull request Oct 28, 2021
…39c285ed2

Pull request: release <- staging/91137235-be6c-4a4d-a848-2d539c285ed2
@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 75.00000% with 5 lines in your changes missing coverage. Please review.

Project coverage is 76.27%. Comparing base (abab62e) to head (6fb8287).
Report is 13321 commits behind head on master.

Files with missing lines Patch % Lines
...zon/awssdk/core/exception/SdkServiceException.java 44.44% 5 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1798      +/-   ##
============================================
- Coverage     76.29%   76.27%   -0.03%     
  Complexity      187      187              
============================================
  Files          1074     1074              
  Lines         32450    32469      +19     
  Branches       2550     2550              
============================================
+ Hits          24759    24767       +8     
- Misses         6438     6446       +8     
- Partials       1253     1256       +3     
Flag Coverage Δ
unittests 76.27% <75.00%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants