Articles Tagged pymongo
Every record in mongoDB has field
_id, that must be unique inside collection.
By default type of this field is ObjectId,
and it is assigned automatically if field is not set.
Lets look at ObjectId more carefully.
It is 12 bytes that includes:
- a 4-byte value representing the seconds since the Unix epoch,
- a 3-byte machine identifier,
- a 2-byte process id, and
- a 3-byte counter, starting with a random value.
As we see, first 4 ...