Use upsert with custom id for improved mongo insert performance.

Evaluation of the performance shows that timeouts were occuring during
processing of the OIDs because the writes to mongo occur in step with
the OID reading, and the monogodb engine ended up taking up most of the CPU.

The find / save nature of the process had more overhead than necessary.
The new approach uses a generated (and guaranteed to be unique) custom id
and uses the mongo upsert feature to automatically create/update the
data as necessary.

In my tests (4 threads, SSD) this shows about a 3x performance improvement
and greatly reduces the device read timeouts occuring.