-
Notifications
You must be signed in to change notification settings - Fork 220
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
Semantics of put operation #300
Comments
The We need to model our existing APIs that support idempotently creating resources using client provided identifiers but don't necessarily support replacing them (like DynamoDB tables)... We could add a trait to resources to indicate this kind of special case (for example, Do you have a use case in mind where this distinction would be important? |
I guess at a minimum having the documentation explain that would be good. I do like the idea of I didn't have a use case in mind, I just didn't understand from the docs what the intention/semantics were. |
The Thanks for your feedback! |
The put lifecycle section says
put
"used to create[s] a resource using identifiers provided by the client". This is a slightly different definition from HTTP PUT, which says that "the state of the target resource [is] created or replaced" (emphasis mine).The
put
operation can be idempotent but not satisfy HTTP PUT semantics. The SQS CreateQueue API is one such example. It only creates queues, it does not update them, but it is idempotent: If you send multiple requests with the same input and a queue did not exist, or a queue with identical properties exists, you'll receive back the queue information every time. If you send multiple requests with the same input and a queue with different properties exists, you'll receive an error every time.Is the Smithy
put
operation supposed to match HTTP PUT's semantics, or something closer to SQS CreateQueue?The text was updated successfully, but these errors were encountered: