-
Notifications
You must be signed in to change notification settings - Fork 140
Spring transaction support #29
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
Comments
Finally some native support: https://aws.amazon.com/blogs/aws/new-amazon-dynamodb-transactions/ |
@derjust It's interesting, it allows you to tranact saves of multiple objects in a single dynamo call, which kind of flys in the face of how spring data does things. We are probably going to have a make a new type of repo that is "crud" for this since it could take pretty much any object. Either that or use the Transactional annotations and do some translation on the backend to wrap all the calls together some how. Any thoughts? |
To expand on that the existing Spring interfaces won't really work for this. There is no persistent connection to the database, beyond that there is no rollback, Amazons API just throws an exception if something is using that item in a transaction at the moment. We are going to have to come up with a new pattern......... |
Also it's only supported in the DynamoDB Async client, (makes sense) and does not have support for the mapper, so if we want to do this we will really have to hit the drawing board From the docs: |
I am thinking about this.I perferm use a threadlocal cache to cache the entity,and the id should generate at local server like snowflowId.My question is how to hit the cache when the query is complicated |
It would be most helpful to be able to wrap or even bind a dynamodb with a normal Spring @transactional method.
The text was updated successfully, but these errors were encountered: