add bson serialization