You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Requesting an enhancement for Dynamo DB Data Repository given variable annotated with @DynamoDBHashKey, would like to see an annotation that is @DynamoDBAutoIncrement on an integer variable where multiple instances of the same @DynamoDBHashKey can be available.
Expected Behavior
This is different use case from updating an item, rather the data pattern of putting the same item key with incremented values on a attribute, i.e. same object but different versioning (Although @DynamoDBAtomicCounter which could be another good add for an annotation as well
see: https://linuxacademy.com/blog/linux-academy/dynamodb-atomic-counters/).
e.g.
Suppose there's a customer with orders that earn points when purchasing x item and there's multiple order numbers under the same customer hash key, but the history of all points must be kept. This way, we can query the primary key (the customer) and the order number and the total count of orders made in history.
The text was updated successfully, but these errors were encountered:
darkmastermindz
changed the title
Enhancement: DynamoDB Auto Increment and Atomic Counters
Implement DynamoDB Auto Increment and Atomic Counter Annotations
Jul 31, 2020
I don't think going with an integer is a great idea with dynamodb. Due to how its indexing works (sort of a b-tree) you should always use a GUID to make sure that paritions are evenly spaces.
Requesting an enhancement for Dynamo DB Data Repository given variable annotated with @DynamoDBHashKey, would like to see an annotation that is @DynamoDBAutoIncrement on an integer variable where multiple instances of the same @DynamoDBHashKey can be available.
Expected Behavior
This is different use case from updating an item, rather the data pattern of putting the same item key with incremented values on a attribute, i.e. same object but different versioning (Although @DynamoDBAtomicCounter which could be another good add for an annotation as well
see: https://linuxacademy.com/blog/linux-academy/dynamodb-atomic-counters/).
e.g.
Suppose there's a customer with orders that earn points when purchasing x item and there's multiple order numbers under the same customer hash key, but the history of all points must be kept. This way, we can query the primary key (the customer) and the order number and the total count of orders made in history.
https://stackoverflow.com/questions/38193431/auto-increment-counter-in-dynamo-db
The text was updated successfully, but these errors were encountered: