[MongoDB] Fix bug with reconnection to new master node 

Fixes bug with raising AutoReconnect exception when MongoDB ReplicaSet
loses connection to primary node.

Change-Id: Id0e81ba60b28d09adff6a10d04b412f25257d8ce
Closes-Bug: #1309555
Merge "[MongoDB] Fix bug with reconnection to new master node "