Hi All,
Can anyone provide the command to get the replications happening in cluster along with its filter expression and existing settings.
Hi All,
Can anyone provide the command to get the replications happening in cluster along with its filter expression and existing settings.
Using the REST APIs: https://docs.couchbase.com/server/current/rest-api/rest-xdcr-intro.html
and https://docs.couchbase.com/server/current/rest-api/rest-xdcr-adv-settings.html
Using the CLI (couchbase-cli xdcr-replicate): https://docs.couchbase.com/server/current/cli/cbcli/couchbase-cli-xdcr-replicate.html
Example of getting list of xdcr replications using the REST API:
curl -X GET -u Administrator:‘password’ http://localhost:8091/pools/default/tasks | jq .
Example of getting global xdcr settings using the REST API:
curl -X GET -u Administrator:‘password’ http://localhost:8091/settings/replications | jq .
Example of getting a specific xdcr replication’s settings using the REST API (the replication id must be specified – the slashes in the replication id should be substituted with %2F):
curl -X GET -u Administrator:‘password’ http://localhost:8091/settings/replications/c2417699d138e7b820ec7e219963bbdd%2Ftestbucket1%2Ftestbucket2 | jq .
Example of getting list of xdcr replications using the CLI:
couchbase-cli xdcr-replicate -c http://localhost:8091 -u Administrator -p ‘password’ --list
Example of getting settings for a specific replication using the CLI:
couchbase-cli xdcr-replicate -c http://localhost:8091 -u Administrator -p ‘password’ --get --xdcr-replicator c2417699d138e7b820ec7e219963bbdd/testbucket1/testbucket2