Код: Выделить всё
8.0.403Код: Выделить всё
M3 Mac). Код репликации следующий:
// Get the database (and create it if it doesn't exist)
var database = new Database("mydb");
var collection = database.GetDefaultCollection();
// Create replicator to push and pull changes to and from
var targetEndpoint = new URLEndpoint(new Uri("ws://localhost:4984/getting-started-db"));
var replConfig = new ReplicatorConfiguration(targetEndpoint);
replConfig.AddCollection(database.GetDefaultCollection());
// Add authentication
replConfig.Authenticator = new BasicAuthenticator("sync", "P@33w0rdS7nc");
replConfig.Continuous = true;
replConfig.ReplicatorType = ReplicatorType.PushAndPull;
// Create replicator
var replicator = new Replicator(replConfig);
replicator.AddChangeListener(OnReplicatorUpdate);
try {
replicator.Start(); //THIS LINE FAILS
} catch (Exception e) {
Console.WriteLine(e);
}
Код: Выделить всё
Process finished with exit code 139.Как добиться успешной репликации.
Подробнее здесь: https://stackoverflow.com/questions/790 ... -sharp-net
Мобильная версия