casmlab / stack

The BITS Lab STACK tool for social media collection and analysis.
http://bits.ischool.syr.edu/
MIT License
1 stars 0 forks source link

Create MongoDB indices at DB creation #6

Closed libbyh closed 7 years ago

libbyh commented 7 years ago

DBs need indices to make retrieval easier/faster.

Example

For user id

db.tweets.createIndex( { user.id : 1 } , { background: true } )

More info here: https://docs.mongodb.com/v3.2/core/index-creation/

As of 3/24/17, Beckett is running MongoDB 3.2.

pratik27shah commented 7 years ago

indices have been created by code for data retrieval of users...so for example if a collector items does not have indexes and user clicks on the term the first thing that happens is index creation .. index