You can download couchbase-sync-gateway-community_1.3.0-274_x86_64.tar.gz in 
the list from that link.

Just tried with iOS build 62 and it works also.

James
On 3 August 2016 at 12:18:01, Nick Pomfret ([email protected]) wrote:

Ah, I'm running a 1.2 sync-gateway, maybe that's the problem?  Is there a 1.3 
build for OSX yet?  Can't see one in here 


/**
 * [email protected]
 * http://twitter.com/nickpomfret
 * https://uk.linkedin.com/in/nick-pomfret-03614a
 */
 

On 3 August 2016 at 12:16, Nick Pomfret <[email protected]> wrote:
1.3.0-62


/**
 * [email protected]
 * http://twitter.com/nickpomfret
 * https://uk.linkedin.com/in/nick-pomfret-03614a
 */
 

On 3 August 2016 at 12:12, James Nocentini <[email protected]> wrote:
Hmm, I just ran the following two curl commands with iOS 1.3.0 build 50 and SG 
1.3.0 build 247.

Create replication

curl -H 'Content-Type: application/json' -vX POST 
'http://localhost:5984/_replicate' \

                                  -d 
'{"source":"untitledapp","target":{"headers":{"Cookie":"SyncGatewaySession=964dfd92221ae028c13710ab83cf4d6742ef225d;
 Path=/sync_gateway; 
Expires=2016-08-04T12:02:41.883045272+01:00"},"url":"http://localhost:4984/sync_gateway"},"continuous":true}'


Stop replication

curl -H 'Content-Type: application/json' -vX POST 
'http://localhost:5984/_replicate' \
                                  -d 
'{"source":"untitledapp","target":{"headers":{"Cookie":"SyncGatewaySession=964dfd92221ae028c13710ab83cf4d6742ef225d;
 Path=/sync_gateway; 
Expires=2016-08-04T12:02:41.883045272+01:00"},"url":"http://localhost:4984/sync_gateway"},"continuous":true,
 "cancel": true}'

The response from the second request is:

{"ok":true}

Which builds of 1.3 of are you running?

James

On Wednesday, 3 August 2016 11:52:22 UTC+1, Nick Pomfret wrote:
Thanks for the reply.  These are the 2 calls to _replicate that start the 
replication tasks (sorry for the formatting):

"{\"source\":\"pc_macmini_0_c5149e0b-d6a6-4d7c-9498-ed311552c663\",\"target\":{\"headers\":{\"Cookie\":\"SyncGatewaySession=a066bb06b86bca4c71d98a8eea69ae4f3a9de400;
 Path=/sync_gateway; Expires=Thu, 04 Aug 2016 10:43:41 
GMT\"},\"url\":\"http://192.168.1.185:4984/sync_gateway\"},\"continuous\":true}";

"{\"source\":{\"headers\":{\"Cookie\":\"SyncGatewaySession=a066bb06b86bca4c71d98a8eea69ae4f3a9de400;
 Path=/sync_gateway; Expires=Thu, 04 Aug 2016 10:43:41 
GMT\"},\"url\":\"http://192.168.1.185:4986/sync_gateway\"},\"target\":\"pc_macmini_0_c5149e0b-d6a6-4d7c-9498-ed311552c663\",\"continuous\":true}";

And these are the 2 calls that are supposed to stop them.  They work on android 
1.3x, but not on iOS - they both result in a 404.

"{\"source\":{\"headers\":{\"Cookie\":\"SyncGatewaySession=a066bb06b86bca4c71d98a8eea69ae4f3a9de400;
 Path=/sync_gateway; Expires=Thu, 04 Aug 2016 10:43:41 
GMT\"},\"url\":\"http://192.168.1.185:4986/sync_gateway\"},\"target\":\"pc_macmini_0_c5149e0b-d6a6-4d7c-9498-ed311552c663\",\"continuous\":true,\"cancel\":true}";

"{\"source\":\"pc_macmini_0_c5149e0b-d6a6-4d7c-9498-ed311552c663\",\"target\":{\"headers\":{\"Cookie\":\"SyncGatewaySession=a066bb06b86bca4c71d98a8eea69ae4f3a9de400;
 Path=/sync_gateway; Expires=Thu, 04 Aug 2016 10:43:41 
GMT\"},\"url\":\"http://192.168.1.185:4984/sync_gateway\"},\"continuous\":true,\"cancel\":true}";
 


/**
 * [email protected]
 * http://twitter.com/nickpomfret
 * https://uk.linkedin.com/in/nick-pomfret-03614a
 */
 

On 3 August 2016 at 10:05, James Nocentini <[email protected]> wrote:
The cancel: true field must be passed along with all the other properties that 
were specified when the replication was created (i.e. source, target, 
continuous etc.)

It's documented here 
http://developer.couchbase.com/mobile/swagger/couchbase-lite/#!/server/post_replicate
 and 
http://developer.couchbase.com/documentation/mobile/1.2/develop/references/couchbase-lite/rest-api/server/post-replicate/index.html.

Can you share the payload of the POST /_replicate request?

James

On Wednesday, 3 August 2016 06:45:25 UTC+1, Nick Pomfret wrote:
I'm trying to cancel a replication task VIA the REST API.  Its not documented 
as far as I can see, but I gather 
(http://docs.couchdb.org/en/stable/api/server/common.html#post--_replicate) 
that I'm supposed to call the `_replicate` endpoint with the same arguments 
that I used to create the task, but adding a `cancel: true` parameter.  It 
works on Android 1.3x but not on iOS 1.3x, and I'm pretty sure that I it used 
to work on 1.2 in iOS (but can't be sure).

Or have I misunderstood, is there another way?


--
You received this message because you are subscribed to a topic in the Google 
Groups "Couchbase Mobile" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/mobile-couchbase/8y3eMdlHtpM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to 
[email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/40f96fa0-bf0e-4758-ab28-7fb12b9cc7d9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google 
Groups "Couchbase Mobile" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/mobile-couchbase/8y3eMdlHtpM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to 
[email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/d172ed72-7c1b-4487-b714-eecdecf06a9c%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups 
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/CACfBfNtkZuDdbEZiWyuXeDkis-xW1G83WXmVQvcwv%3D-MwwsuqQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/etPan.57a1d49c.347c7b54.2ad%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to