added persist to mongodb