Add mongoose connection err handling.

Please review and merge to develop.