The current snapshot behavior doesn't really tell the user what's going on. After you request a snapshot, it says its looking for one and then just waits for a while until either the snapshot is ready or it suggests that you re-submit. The system should be able to check to see if there is a background task running or not. If it is actively running, we should say that. And not prompt to re-submit.
Make sure any monq_task queries will be efficient, by using existing indexes. Constructing an ObjectId from timestamp and querying on _id to just look for recent tasks may be helpful.
Originally by: kharechko
I am new to allura. Will next request be efficient enought?
It don't use objectid timestamp, but simplify code.
If you can add 'status' to that query, then it would be. But without it, it will not use any index:
BasicCursor
means no index is used,BtreeCursor
means an index is being used. See http://docs.mongodb.org/manual/core/index-compound/ for more info on mongo indexes (including the Prefixes section at bottom). To see what indexes are specified for a model/collection, look at theindexes
var within the__mongometa__
section of our python class. And there is always an index on_id
Closed #503.
je/42cc_6905
Hey Mykola,
I did quite a bit of refactoring on this in branch
tv/6905
before merging to master. Just letting you know so you can take a look at what I changed if you'd like.