Q: Skip initial scan for tailable cursor queries with awaitdata=true and storage engine wiredTiger I am using the mongodb oplog.$main collection in a single master instance for even streaming in my app. When my app starts, it queries the oplog collection with a tailable cursor waiting for new data, but mongo cpu spikes because this query scans the full oplog collection (which in my case is 25GB). From mongodb documentation:


*

*Because tailable cursors do not use indexes, the initial scan for the query may be expensive; but, after initially exhausting the cursor, subsequent retrievals of the newly added documents are inexpensive.


Is there any way to skip the initial scan of the query? I am only interested in new documents added to oplog.
I have tried with {oplogReplay: true} and the filter {ts: {$gt: lastOplogTime}}, but the mongo CPU still spikes. I am using mongo 3.0.3 with storage engine wiredTiger. Also, using sort({$natural: -1}) does not work since I get this error from mongo:


*

*invalid sort specified for tailable cursor: { $natural: -1 }.


Looks like the sort error is due to be using wiredTiger.
Any help is much appreciated. Thanks!
