草庐IT

bson-ext

全部标签

ruby-on-rails - 恢复 mongodb 数据库 .bson 和 .json 文件

在这个名为my_backup的文件夹中,我有一个mongodb数据库转储,其中包含我所有的models/collections,例如:admins.bsonadmins.metadata.jsoncategories.bsoncategories.metadata.jsonpages.bsonpages.metadata.json...我在mongodb上有一个名为ubuntu_development的数据库。我正在使用rails3+mongoid如何将文件夹my_backup中的所有模型/集合导入/恢复到我的数据库ubuntu_development非常感谢!

ruby-on-rails - 恢复 mongodb 数据库 .bson 和 .json 文件

在这个名为my_backup的文件夹中,我有一个mongodb数据库转储,其中包含我所有的models/collections,例如:admins.bsonadmins.metadata.jsoncategories.bsoncategories.metadata.jsonpages.bsonpages.metadata.json...我在mongodb上有一个名为ubuntu_development的数据库。我正在使用rails3+mongoid如何将文件夹my_backup中的所有模型/集合导入/恢复到我的数据库ubuntu_development非常感谢!

java - MongoDB Java 插入抛出 org.bson.codecs.configuration.CodecConfigurationException : Can't find a codec for class io. github.ilkgunel.mongodb.Pojo

我正在使用Java学习MongoDB。我正在尝试使用Java驱动程序将数据插入MongoDB。我正在像MongoDB教程中一样进行插入,而且一切都很好。但是如果我想插入一个变量,当我运行代码时,驱动程序会抛出这样的错误:org.bson.codecs.configuration.CodecConfigurationException:Can'tfindacodecforclassio.github.ilkgunel.mongodb.Pojo.我在StackOverflow中搜索过这样的问题,但我什么都不懂,也找不到任何东西可以解决这个错误。我的代码如下。如何解决这个问题?我正在使用此代

java - MongoDB Java 插入抛出 org.bson.codecs.configuration.CodecConfigurationException : Can't find a codec for class io. github.ilkgunel.mongodb.Pojo

我正在使用Java学习MongoDB。我正在尝试使用Java驱动程序将数据插入MongoDB。我正在像MongoDB教程中一样进行插入,而且一切都很好。但是如果我想插入一个变量,当我运行代码时,驱动程序会抛出这样的错误:org.bson.codecs.configuration.CodecConfigurationException:Can'tfindacodecforclassio.github.ilkgunel.mongodb.Pojo.我在StackOverflow中搜索过这样的问题,但我什么都不懂,也找不到任何东西可以解决这个错误。我的代码如下。如何解决这个问题?我正在使用此代

gradle - 如何将 ext.* 变量放入 build.gradle.kts 中的插件 block 中

我的构建文件如下所示:valnexusBaseUri:Stringbyextravalgradle_version:Stringbyextravalkotlin_version:Stringbyextrabuildscript{valnexusBaseUribyextra{"https://mynexusserver/nexus"}valgradle_versionbyextra{"4.1"}valkotlin_versionbyextra{"1.1.4-3"}valspringBoot_versionbyextra{"2.0.0.M3"}repositories{maven{url=

AndroidJUnit4.class 已弃用 : How to use androidx. test.ext.junit.runners.AndroidJUnit4?

对于我正在使用的仪器测试@RunWith(AndroidJUnit4.class)来自importandroidx.test.runner.AndroidJUnit4;为了建立我的测试用例。现在这一行被标记为已弃用,并提示使用AndroidJUnit4fromimportandroidx.test.ext.junit.runners.AndroidJUnit4但是,如果我尝试从命名包中导入AndroidJUnit4会收到错误,即无法解析ext。你有什么想法,应该在gradle中包含什么包来解决这个问题? 最佳答案 根据thedocu

php - 如何通过 docker-php-ext-install 为 php 安装扩展?

为了resolveanissue,我现在正在尝试通过安装mysqlpdodocker-php-ext-install正如READMEofthephpimage中指出的那样.但我的电话失败了,说明:Librarieshavebeeninstalledin:/usr/src/php/ext/mysqli/modulesIfyoueverhappentowanttolinkagainstinstalledlibrariesinagivendirectory,LIBDIR,youmusteitheruselibtool,andspecifythefullpathnameofthelibrary

c# - 将 BSON 数组添加到 MongoDB 中的 BsonDocument

如何使用C#驱动程序将BsonArray添加到MongoDB中的BsonDocument?我想要这样的结果{author:'joe',title:'Yetanotherblogpost',text:'Hereisthetext...',tags:['example','joe'],comments:[{author:'jim',comment:'Idisagree'},{author:'nancy',comment:'Goodpost'}]} 最佳答案 您可以使用以下语句在C#中创建上述文档:vardocument=newBsonD

c# - 将 BSON 数组添加到 MongoDB 中的 BsonDocument

如何使用C#驱动程序将BsonArray添加到MongoDB中的BsonDocument?我想要这样的结果{author:'joe',title:'Yetanotherblogpost',text:'Hereisthetext...',tags:['example','joe'],comments:[{author:'jim',comment:'Idisagree'},{author:'nancy',comment:'Goodpost'}]} 最佳答案 您可以使用以下语句在C#中创建上述文档:vardocument=newBsonD

c++ - 二进制到文本编码、非打印字符、 Protocol Buffer 、mongodb 和 bson

我有一个候选键(mongodb候选键,__id),它在ProtocolBuffer中如下所示:messageqrs_signature{requireduint32region_id=1;repeatedfixed32urls=2;};当然,我不能在我的bson文档中使用ProtocolBuffer编码字符串(通过ParseToString(std::string)),因为它可以包含非打印字符。因此,我使用ascii85编码对数据进行编码(使用thislibrary)。我有两个问题。b85编码是否安全。什么是bson'sbinarytypefor?有什么方法可以使用mongodbAPI