Refactor mongodb connection

This refactoring to mongodb connection handling will solve:
1. username or password with special chars like @ won't be handled correctly to connect to mongodb via the connection string uri, so this refactor solves that
2. exit on mongodb error instead of hang the nodejs app idle
Why so many process URIs? In my opinion, let the user change the one included if necessary, but no need to include one for every database service.