now connects to a mongodb database