You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by fl...@apache.org on 2019/07/06 11:43:52 UTC

[couchdb-documentation] branch localRepl created (now ce56a5f)

This is an automated email from the ASF dual-hosted git repository.

flimzy pushed a change to branch localRepl
in repository https://gitbox.apache.org/repos/asf/couchdb-documentation.git.


      at ce56a5f  Add note calling attention to the new fully-qualified URL requirement

This branch includes the following new commits:

     new 601f599  Update replication docs to use fully qualified URLs
     new b8eb148  Update local replication examples
     new ce56a5f  Add note calling attention to the new fully-qualified URL requirement

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[couchdb-documentation] 02/03: Update local replication examples

Posted by fl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

flimzy pushed a commit to branch localRepl
in repository https://gitbox.apache.org/repos/asf/couchdb-documentation.git

commit b8eb1482e00a34c6e21f44b91af96825884b31ac
Author: Jonathan Hall <fl...@flimzy.com>
AuthorDate: Sat Jul 6 13:24:30 2019 +0200

    Update local replication examples
---
 src/intro/api.rst | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/intro/api.rst b/src/intro/api.rst
index 82e067b..7d47720 100644
--- a/src/intro/api.rst
+++ b/src/intro/api.rst
@@ -605,7 +605,7 @@ easy to make)::
 Now we can use the database `albums-replica` as a replication target::
 
     curl -vX POST http://127.0.0.1:5984/_replicate \
-         -d '{"source":"albums","target":"albums-replica"}' \
+         -d '{"source":"http://127.0.0.1:5984/albums","target":"http://127.0.0.1:5984/albums-replica"}' \
          -H "Content-Type: application/json"
 
 .. note::
@@ -664,7 +664,7 @@ HTML) and so far we've seen links relative to the server we're working on
 (hence local). You can also specify a remote database as the target::
 
     curl -vX POST http://127.0.0.1:5984/_replicate \
-         -d '{"source":"albums","target":"http://example.org:5984/albums-replica"}' \
+         -d '{"source":"http://127.0.0.1:5984/albums","target":"http://example.org:5984/albums-replica"}' \
          -H "Content-Type:application/json"
 
 Using a *local source* and a *remote target* database is called *push
@@ -683,7 +683,7 @@ replication*. This is great for getting the latest changes from a server that
 is used by others::
 
     curl -vX POST http://127.0.0.1:5984/_replicate \
-         -d '{"source":"http://example.org:5984/albums-replica","target":"albums"}' \
+         -d '{"source":"http://example.org:5984/albums-replica","target":"http://127.0.0.1:5984/albums"}' \
          -H "Content-Type:application/json"
 
 Finally, you can run remote replication, which is mostly useful for management


[couchdb-documentation] 01/03: Update replication docs to use fully qualified URLs

Posted by fl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

flimzy pushed a commit to branch localRepl
in repository https://gitbox.apache.org/repos/asf/couchdb-documentation.git

commit 601f599d8c59ee7be6ea316a56b6ac2119b34489
Author: Jonathan Hall <fl...@flimzy.com>
AuthorDate: Sat Jul 6 13:14:41 2019 +0200

    Update replication docs to use fully qualified URLs
---
 src/api/server/common.rst | 20 +++++++++-----------
 1 file changed, 9 insertions(+), 11 deletions(-)

diff --git a/src/api/server/common.rst b/src/api/server/common.rst
index 69341e6..033cc1d 100644
--- a/src/api/server/common.rst
+++ b/src/api/server/common.rst
@@ -608,15 +608,13 @@
     :<json string filter: The name of a :ref:`filter function <filterfun>`.
     :<json string proxy: Address of a proxy server through which replication
       should occur (protocol can be "http" or "socks5")
-    :<json string/object source: Source database name or URL or an object
-      which contains the full URL of the source database with additional
-      parameters like headers. Eg: 'source_db_name' or
-      'http://example.com/source_db_name' or
+    :<json string/object source: Fully qualified source database URL or an
+      object which contains the full URL of the source database with additional
+      parameters like headers. Eg: 'http://example.com/source_db_name' or
       {"url":"url in here", "headers": {"header1":"value1", ...}}
-    :<json string/object target: Target database name or URL or an object
-      which contains the full URL of the target database with additional
-      parameters like headers. Eg: 'target_db_name' or
-      'http://example.com/target_db_name' or
+    :<json string/object target: Fully qualified target database URL or an
+      object which contains the full URL of the target database with additional
+      parameters like headers. Eg: 'http://example.com/target_db_name' or
       {"url":"url in here", "headers": {"header1":"value1", ...}}
     :>header Content-Type: - :mimetype:`application/json`
                            - :mimetype:`text/plain; charset=utf-8`
@@ -660,13 +658,13 @@
 
         POST /_replicate HTTP/1.1
         Accept: application/json
-        Content-Length: 36
+        Content-Length: 80
         Content-Type: application/json
         Host: localhost:5984
 
         {
-            "source": "db_a",
-            "target": "db_b"
+            "source": "http://127.0.0.1:5984/db_a",
+            "target": "http://127.0.0.1:5984/db_b"
         }
 
     **Response**


[couchdb-documentation] 03/03: Add note calling attention to the new fully-qualified URL requirement

Posted by fl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

flimzy pushed a commit to branch localRepl
in repository https://gitbox.apache.org/repos/asf/couchdb-documentation.git

commit ce56a5f1911485d53fa1531663ee08c755f1ec86
Author: Jonathan Hall <fl...@flimzy.com>
AuthorDate: Sat Jul 6 13:43:16 2019 +0200

    Add note calling attention to the new fully-qualified URL requirement
---
 src/api/server/common.rst | 4 ++++
 src/intro/api.rst         | 4 ++++
 2 files changed, 8 insertions(+)

diff --git a/src/api/server/common.rst b/src/api/server/common.rst
index 033cc1d..0f29497 100644
--- a/src/api/server/common.rst
+++ b/src/api/server/common.rst
@@ -652,6 +652,10 @@
     :json string start_time:  Date/Time replication operation started in
       :rfc:`2822` format
 
+.. note::
+    As of CouchDB 2.0.0, fully qualified URLs are required for both the
+    replication `source` and `target` parameters.
+
     **Request**
 
     .. code-block:: http
diff --git a/src/intro/api.rst b/src/intro/api.rst
index 7d47720..04aaa76 100644
--- a/src/intro/api.rst
+++ b/src/intro/api.rst
@@ -609,6 +609,10 @@ Now we can use the database `albums-replica` as a replication target::
          -H "Content-Type: application/json"
 
 .. note::
+    As of CouchDB 2.0.0, fully qualified URLs are required for both the
+    replication `source` and `target` parameters.
+
+.. note::
     CouchDB supports the option ``"create_target":true`` placed in the JSON
     POSTed to the :ref:`_replicate <api/server/replicate>` URL. It implicitly
     creates the target database if it doesn't exist.