Rewrite of dinotrap on mongodb