Refactored mongo connections for better pooling