Does dynamodb have commit and rollback transaction http APIs?

1

My traditional app has the following style of doing transaction against a database such as postgres or oracle.

  1. Acquire a read-committed transaction from the server.
  2. Use that transaction "object" for subsequent db requests.
  3. Based on how those request(s) were serviced - commit or rollback the transaction accordingly.

In other words, I am trying to combine independent db operations (aka requests) under the same transaction session. My application has control on how that session is managed.

Does dynamodb allow for this kind of use case?

gefragt vor 2 Jahren2889 Aufrufe
1 Antwort
2

DynamoDB does not provide the ability to ROLLBACK a transaction like you would do on a relational system. However, it does provide Transactional API's which allow for ACID compliance. You can submit batches of up to 100 items as a single request and ensure that wither all requests succeed or none at all.

For your use-case you may be able to make use of version control: https://aws.amazon.com/blogs/database/implementing-version-control-using-amazon-dynamodb/

profile pictureAWS
EXPERTE
beantwortet vor 2 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen