Make sure we copy data into/out of MIM, add support for $pushAll and $pull-ing atoms from lists

Signed-off-by: Rick Copeland <rick@arborian.com>
Annotate BSON errors also

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
s/neq/ne/

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Re-add mim regex support

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Fix mim limit; make all() respect skip and limit

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Fix mim

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Don't raise KeyError on non-existent sub-keys

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Don't modify the orginal spec

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Lock the manager descriptor when doing auto-ensure-indexes

Signed-off-by: Rick Copeland <rick@arborian.com>
$pop should remove first element when arg is not 1, not second element

Signed-off-by: Rick Copeland <rick@arborian.com>
update version to 0.3.4

Signed-off-by: Doug Hellmann <doug.hellmann@gmail.com>
add more detail to build steps

Signed-off-by: Doug Hellmann <doug.hellmann@gmail.com>
mim patch
add limit, skip option to find
find_and_modify use update instead of insert  when upsert
find_and_modify filter result by fields
ensure_index use name as index_name
add _op_unset
add $each support for _op_push
add $each support for addToSet
add _op_pullAll
add __delitem__ on matchlist and matchdoc for _op_unset
_project skip keyerror if a field in fields doesn't exist
Normalize (with bcopy) the spec and doc in match
Don't copy the document when doing a match, only the spec; we sometimes need to use the document we found for an update.

Signed-off-by: Rick Copeland <rick@arborian.com>
[allura:tickets:#6208] use background=True when ensuring indexes

Mongo defaults to creating indexes as blocking foreground operations
(presumably for backwards compatibility), but this is dangerous
since it is blocking.  Use background=True when ensuring indexes
so that adding a new index to a model doesn't cause the mongo server
to block up as soon as that new model is in use.

http://docs.mongodb.org/manual/core/indexes/#index-creation-background
Bumped version
Replace deprecated ttl by cache_for

Signed-off-by: Julien Danjou <julien@danjou.info>
Fix index_information to return all index creation

This mimics what's done by pymongo.

Signed-off-by: Julien Danjou <julien@danjou.info>
bump version for mim changes

Signed-off-by: Doug Hellmann <doug.hellmann@gmail.com>