There is a lot more you should learn about DynamoDB but I appreciate the effort of the author. Please read the AWS documentation, it's not that big and explains vital things that just aren't in this article. Very important things like:
- LSI can't be created after table is created
- GSI late creation generate back pressure on main table
- If you have an LSI, your table will not scale beyond 10GB
- How often a table will scale up and down per day/hour?
- Cost of auto-scaling in cloudwatch (alarms aren't free)
...and so much more. I've been working with Dynamodb for over 2 years now and I love it.
One note on this -- if you have an LSI, you can't have an item collection larger than 10GB, where an item collection refers to all the items with the same partition key in your main table and your LSI.
A DynamoDB table with an LSI can scale far beyond 10GB. That said, I would avoid LSIs in almost all circumstances. Just go with a GSI.
Thank you for the clarification abd12, you are right. I only create LSI if I know for sure the data within a given shard will not go beyond 10GB... since we never really do we always go with GSI.
- LSI can't be created after table is created
- GSI late creation generate back pressure on main table
- If you have an LSI, your table will not scale beyond 10GB
- How often a table will scale up and down per day/hour?
- Cost of auto-scaling in cloudwatch (alarms aren't free)
...and so much more. I've been working with Dynamodb for over 2 years now and I love it.