10gen-labs/mongo-connector — pull request #129 by sdz-dalbrecht (2014-05-22 12:32:27+00:00)
Title: Elasticsearch connector delete ops

Hi,

when using the mongo-connector for elasticsearch we discovered two problems.

1. If you specify a index name via `-g DEST_NS_SET` param the generated elasticsearch url which is used for delete operations is wrong. instead of the specified index name it contained the mongo ns value. to fix this we had to add `entry['ns'] = ns` for the oplog_manager.py remove code like its already the case in the update code

2. If you update a document in mongo db without using `$set` or `$unset` operations (e.g. `db.col.update({"_id" : ObjectId(abc)}, {"a" : 1, "b" : 2 } )` the old document was sent to elasticsearch instead of the updated one