write data to mongo. v preliminary.