Addding mongo code.