Upgrade pymongo usage from deprecated connection to client

LMS-1551

@cpennington @chrisndodge Please review or delegate.