https://github.com/tallesl/py-dynamo-size
Roughly calculates DynamoDB item size.
https://github.com/tallesl/py-dynamo-size
Last synced: about 2 months ago
JSON representation
Roughly calculates DynamoDB item size.
- Host: GitHub
- URL: https://github.com/tallesl/py-dynamo-size
- Owner: tallesl
- Created: 2020-02-14T12:32:18.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2020-03-09T13:06:23.000Z (about 5 years ago)
- Last Synced: 2025-01-11T01:29:48.512Z (4 months ago)
- Language: Python
- Homepage: https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/CapacityUnitCalculations.html
- Size: 2.93 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# dynamo-size
[](https://pypi.org/project/dynamo-size)
Roughly calculates [DynamoDB item size](https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/CapacityUnitCalculations.html).
```py
item = {
'Id': 123,
'Names': [
'foo',
'bar',
'qux',
# 500 more names
]
}from dynamo_size import calculate_bytes, calculate_kbytes
calculate_bytes(item) # returns 2025
calculate_kbytes(item) # return 1.9775390625 (2025 / 1024)
```