Home > other >  AWS service to store single key value that is updated daily
AWS service to store single key value that is updated daily

Time:11-09

What AWS service is appropriate for storing a single key-value pair data that is updated daily? The stored data will be retrieved by other several services throughout the day (~ 100 times total per day).

My current solution is to create and upload a JSON to an S3 bucket. All other services download the JSON and get the data. When it's time to update the data, I create a new JSON and upload it to replace the previously uploaded JSON. This works pretty well but I'm wondering if there is a more appropriate way.

CodePudding user response:

There's many:

  • AWS Systems Manager Parameter Store
  • AWS Secrets Manager
  • Dynamo
  • S3

^ those are some of the most common. Without knowing more I'd suggest you consider Dynamo or Param Store. Both are simple and inexpensive--although S3 is fine, too.

CodePudding user response:

The only reason to not use S3 is governance of the key expires etc., automatically from AWS side - like using a secret manager - therefore, giving it to third parties will be much harder.

Your solution seems very good, especially since S3 IS the object store database - json is an object.

The system you described is such a low usage that you shouldn't spend time thinking if there is any better way :)

Just make sure you are aware that amazon S3 provides read-after-write consistency for PUTS of new objects in your S3 bucket in all regions with one caveat. The caveat is that if you make a HEAD or GET request to the key name (to find if the object exists) before creating the object, Amazon S3 provides eventual consistency for read-after-write

and to refer to your comment:

The S3 way seemed a little hacky, so I am trying to see if there is a better approach

S3 way is not hacky at all - intended use of S3 is to store some objects in the key-value database :)

  • Related