Check for missing mongodb://
Use regex to obtain port number