outputs to mongo,mysql.