Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to disable RavenDB replication

Tags:

c#

ravendb

How do I disable RavenDB replication? The reason for that is I have a simple database on one server and I don't need any replication at this point.

IDocumentStore tmpStore = new DocumentStore
{
    Url = url
};

tmpStore.Initialize();
tmpStore.DatabaseCommands.EnsureDatabaseExists(dbName); // WebException

If I try to ensure that database was created I get a WebException with HTTP status 404. This error occurred when RavenDB makes request to /docs/Raven/Replication/Destinations. Or shall I just ignore this exception?

like image 523
oleksii Avatar asked May 03 '11 12:05

oleksii


2 Answers

The web exception is thrown and caught internally inside RavenDB Client. You can safely continue working, and your code will execute properly.

like image 87
Ayende Rahien Avatar answered Oct 29 '22 17:10

Ayende Rahien


The 404 is caused by Raven checking to see if you have replication setup and you can safely ignore it.

http://groups.google.com/group/ravendb/browse_thread/thread/5cdde7854bc929f4

http://groups.google.com/group/ravendb/browse_thread/thread/6cb950e1eb760c08/c09ce446a3f4e99f

like image 43
Adam Cooper Avatar answered Oct 29 '22 15:10

Adam Cooper