Skip to content

docs(idempotency): new sequence diagrams, fix idempotency record vs DynamoDB TTL confusion #2074

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

Conversation

heitorlessa
Copy link
Contributor

@heitorlessa heitorlessa commented Mar 31, 2023

Issue number: #2023

Summary

Improves Idempotency documentation after discussion with @pmarko1711 on Idempotency Record expiration vs DynamoDB TTL expiration.

As I improved it, I've noticed we were light on sequence diagrams to explain common scenarios Idempotency handles it (we can add more later).

Changes

Please provide a summary of what's being changed

  • Created multiple sub-sections to ease referencing sequence diagrams throughout docs
  • Added new sequence diagram to demonstrate in-memory cache flow
  • Added new sequence diagram to demonstrate how we handle records that expired
  • Added new sequence diagram to demonstrate in-flight requests
  • revamped timeout sequence diagram
  • Added idempotency record terminology along with a diagram to explain what's in it (missed that when explaining to Peter how it looks like)
  • Added new banner to address idempotency record vs DynamoDB Time-to-live (TTL) confusion

Unrelated but sorely needed changes after

  • Within Choosing a payload subset for idempotency, improved payment scenario by using composite idempotency hash with JMESPath. It's way more realistic and less error-prone to HTTP header change for example.
  • Hint customers can choose a portion of the payload earlier in the docs

User experience

Please share what the user experience looks like before and after this change

New and revamped sequence diagrams depicting Idempotency Record Status too

image

New Idempotency Record terminology

image

Address confusion between Idempotency Record expiration vs DynamoDB time-to-live (TTL)

image

Adding screenshots shortly

Checklist

If your change doesn't seem to apply, please leave them unchecked.

Is this a breaking change?

RFC issue number:

Checklist:

  • Migration process documented
  • Implement warnings (if it can live side by side)

Acknowledgment

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

@heitorlessa heitorlessa requested a review from a team as a code owner March 31, 2023 13:32
@heitorlessa heitorlessa requested review from leandrodamascena and removed request for a team March 31, 2023 13:32
@boring-cyborg boring-cyborg bot added the documentation Improvements or additions to documentation label Mar 31, 2023
@pull-request-size pull-request-size bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Mar 31, 2023
@heitorlessa
Copy link
Contributor Author

@awslabs/aws-lambda-powertools-typescript @awslabs/aws-lambda-powertools-java major improvement you can copy/paste to Idempotency docs once @leandrodamascena reviews it.

@leandrodamascena
Copy link
Contributor

Starting the review.

@heitorlessa
Copy link
Contributor Author

fixing PR title shortly.. picked up my last commit somehow

@heitorlessa heitorlessa changed the title docs(idempotency): upgrade sample runtime to 3.9 docs(idempotency): new sequence diagrams, fix idempotency record vs DynamoDB TTL confusion Mar 31, 2023
Copy link
Contributor

@leandrodamascena leandrodamascena left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just added some comments, but it's a huge improvement to this documentation!

Really good job Heitor!

Copy link
Contributor

@leandrodamascena leandrodamascena left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved!

@leandrodamascena leandrodamascena merged commit 3873f53 into aws-powertools:develop Mar 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants