OLAP Object Queries : Multi-shard and Uncommitted Data Queries

Multi-shard and Uncommitted Data Queries
An object query whose range or shards parameter selects more than one shard is called a multi-shard query. Because each shard is analogous to a self-contained database, an object with a given ID may be inserted into the same table in multiple shards. A single multi-shard query could therefore select objects with the same ID in multiple shards. However, since a given object ID is returned only once, only object amount the duplicate IDs is returned from one of the shards.
In the query result, the totalobjects field indicates how many objects were selected across all shards, including those with duplicate IDs. For each object returned, the _shard field indicates the shard from which the corresponding object was selected. Example (in JSON):
GET Email/Message/_query?q=Size>10000&range=&uncommitted=true
{"results": {
"totalobjects": "11",
"docs": [
{"doc": {
"_ID":" +/pz/q4Jf8Rc2HK9Cg08TA==",
"_shard": "2015-01-01",
...
}},
{"doc": {
"_ID": "+/wqUBY1WsGtb7zjpKYf7w==",
"_shard": "2015-01-02",
...
}},
...
]
}}
A similar process occurs when a query includes unmerged batches by adding the option &uncommitted=true. An unmerged batch acts like a “mini shard”: if it includes object IDs that already exist in the merged (“live”) shard, only one of the objects is returned by the query. Furthermore, the update batches will not be applied to the “live” object, hence multi-value scalar updates and link updates will not be reflected. If an update batch deletes an object, the delete will not yet be applied.
However, when update batches only add new objects, it can be beneficial to include uncommitted data. Essentially, the query includes the latest, live data without having to wait for the underlying shard to be merged.