Very partial list of errors defined in smithy S3 model
See original GitHub issueHi
For context:
- I am working on this project that uses the S3 model to interact with S3 clients and servers - https://github.com/s3d-rs/s3d.
- This is a followup from https://github.com/awslabs/smithy-rs/issues/1150.
When I look at the S3 smithy model, I find that it lacks a lot of error definitions for operations. Here is a list of all the operations that have errors defined:
$ node -e 'm=require("./smithy-rs/aws/sdk/aws-models/s3.json"); Object.entries(m.shapes).forEach(([n,s])=>{ if (s.type==="operation" && s.errors) console.log(n, "---", s.errors.map(x=>x.target).join(",")); })'
com.amazonaws.s3#AbortMultipartUpload --- com.amazonaws.s3#NoSuchUpload
com.amazonaws.s3#CopyObject --- com.amazonaws.s3#ObjectNotInActiveTierError
com.amazonaws.s3#CreateBucket --- com.amazonaws.s3#BucketAlreadyExists,com.amazonaws.s3#BucketAlreadyOwnedByYou
com.amazonaws.s3#GetObject --- com.amazonaws.s3#InvalidObjectState,com.amazonaws.s3#NoSuchKey
com.amazonaws.s3#GetObjectAcl --- com.amazonaws.s3#NoSuchKey
com.amazonaws.s3#HeadBucket --- com.amazonaws.s3#NotFound
com.amazonaws.s3#HeadObject --- com.amazonaws.s3#NotFound
com.amazonaws.s3#ListObjects --- com.amazonaws.s3#NoSuchBucket
com.amazonaws.s3#ListObjectsV2 --- com.amazonaws.s3#NoSuchBucket
com.amazonaws.s3#PutObjectAcl --- com.amazonaws.s3#NoSuchKey
com.amazonaws.s3#RestoreObject --- com.amazonaws.s3#ObjectAlreadyInActiveTierError
This is clearly a tiny fraction of the real errors that this API can return. See https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html
Is there a way to contribute to the model definition to make it represent the S3 errors correctly?
Thanks!
Issue Analytics
- State:
- Created a year ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
AWS Core Specification - Smithy 2.0 - Open Source at AWS
An AWS service is defined using the aws.api#service trait. This trait provides information about the service like the name used to generate AWS...
Read more >1. The Smithy model
Defines a list of common errors that every operation bound within the closure of the service can return. Each provided shape ID MUST...
Read more >Error Responses - Amazon Simple Storage Service
Error Code Description HTTP Status Code
AccessControlListNotSupported The bucket does not allow ACLs. 400 Bad Request
AccessDenied Access Denied 403 Forbidden
BucketAlreadyOwnedByYou 409 Conflict (in all...
Read more >Smithy: A language for defining services and SDKs
Think joining multiple microservices in to a single public interface or splitting out different service/client models based on tags or traits.
Read more >Client in aws_sdk_s3::client - Rust - Docs.rs
If you specified server-side encryption either with an Amazon S3-managed ... check to ensure that the encryption key was transmitted without error.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Hi there. Since this is a cross-SDK issue I’ve created a tracking issue at aws/aws-sdk#376. Please follow that issue for updates instead.
Thank you @gosar - I really appreciate your update.