using bson instead of json