data switch to mongodb