Dan Allan
Dan Allan
This was superseded by work upstream in Tiled core.
[Copied from Slack] This is the place to start: https://github.com/bluesky/databroker/blob/a2a5d6600ecf75efdd1c70cb67a0ebe2a1584bbd/databroker/mongo_normalized.py#L87-L113
The ObjectId is the document creation time, which _may_ be close to `start_doc.time` but may not. Consider the case where a MongoDB was populated by databroker-unpack from msgpack documents. Or...
In terms of priority, I think it's clear that fast (and correct...) search is more critical than RunStart document insert time.
It looks like this one will do it. https://github.com/bluesky/suitcase-mongo/blob/4895ad9784784bcbc346fbffdc7f1694f6739cc0/suitcase/mongo_normalized/__init__.py#L89-L91
In practice, we are always sorting by time and looking up by time range or by `scan_id`. I think that one index covers both.
Fair, sorry for the false trail. I dashed this off in too much of a hurry, and I hadn't looked at the index creation in awhile.
https://www.mongodb.com/blog/post/building-with-patterns-the-document-versioning-pattern
Can you list some ideas here? My opening suggestion is `header` or `bluesky_header_v1`.
Thanks for this clear description and for your patience with the delayed reply. We are in the final stages of a major internal refactor of databroker, moving from [`intake`](https://github.com/intake/intake) to...