fixed issue to allow connection to remote mongodb from spring configuration