Asked
Active
Viewed 129 times
0
We have a business requirement to deprecate certain field values("**State**"). So we need to scan the entire db and find these deprecated field values and take the last record of that partition key(as there can be multiple records for the same partition key, sort key is LastUpdatedTimeepoch), then update the record. Right now the table contains around 600k records. What's the best way to do this without bringing down the db service in production?
I see this thread could help me https://stackoverflow.com/questions/36780856/complete-scan-of-dynamodb-with-boto3
But my main concern is - This is a one time activity. As this will take time, we cannot run this in AWS lambda since it will exceed 15 minutes. So where can I keep the code running for this?

Geethu Unnikrishnan
- 21
- 1
1 Answers
0
Create EC2 instance and assign role to access dynamo db and run function in EC2 instance.

Indrajeet Mourya
- 1
- 3