RavenDB 中的多个数据库
我们计划在生产环境中使用RavenDB,不同的客户将拥有不同的数据库,但我想使用相同的RavenDB实例。
本页介绍了多个数据库的创建:http://ravendb.net/documentation/multiple-databases
我尝试在服务器文件夹中创建一个 Databases
文件夹,然后创建一个名为 MyCustomerName
(不带扩展名)的文件。我尝试过其他不同的方法,但我不断收到消息:
{
"Url": "/databases/MyCustomerName",
"Message": "Could not find a database named: MyCustomerName",
"Error": "Could not find a database named: MyCustomerName"
}
上面的页面是我能找到的关于该主题的唯一来源,我确信我只需要一点指导即可完成这项工作。
We are planning to use RavenDB in a production environment and different customers will have different databases, but I would like to use the same instance of RavenDB.
This page describes the creation of multiple databases: http://ravendb.net/documentation/multiple-databases
I have tried to create a Databases
-folder in the server-folder and then created a file named MyCustomerName
(without extension). I have tried different other things, but I keep getting the message:
{
"Url": "/databases/MyCustomerName",
"Message": "Could not find a database named: MyCustomerName",
"Error": "Could not find a database named: MyCustomerName"
}
This page above is the only source I could find on the subject and I'm sure I only need a little direction to make this work.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
斯蒂芬,
该文档不讨论“文件”,而是讨论“文档”。
您应该在主数据库中创建一个描述这一点的文档。
您还可以通过调用以下 API 使用 API 来执行此操作:
Stephan,
the documentation doesn't talk about a "file", it talks about a "document".
You should be creating a document inside the master database that describe this.
You can also do this using the API by calling: