DynamoDB Global Secondary Index to increase performance -


i designing application tracing call activity.

each call can either terminated or activated. application query database every minute generate list of activate calls. there can 1000 calls per second.

how should design database? should have "call" table , global secondary index on "state" attribute can equal "activate" or "terminated"

or

a "call" table , global secondary index on "isactive" attribute present active calls only.

problems may faced if go out schema have suggested in question:

  1. calllist table 'state' gsi, way able query gsi , active calls, effect performance there limited values partition key (i assuming wont deleting record either, table grow huge in no time)
  2. calllist table gsi on isactive, have same above problem of rows have "isactive=false"

my proposed schema:

keep separate activecall table having entry of active calls, way don't have worry size of table or gsi result in paying less, once call terminated can remove entry table.


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -