Create a follower Added in 6.5.0
Create a cross-cluster replication follower index that follows a specific leader index. When the API returns, the follower index exists and cross-cluster replication starts replicating operations from the leader index to the follower index.
Path parameters
-
The name of the follower index
Query parameters
-
wait_for_active_shards number | string
Sets the number of shard copies that must be active before returning. Defaults to 0. Set to
all
for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1)
Body Required
-
leader_index string
-
max_read_request_size string
-
max_retry_delay string
A duration. Units can be
nanos
,micros
,ms
(milliseconds),s
(seconds),m
(minutes),h
(hours) andd
(days). Also accepts "0" without a unit and "-1" to indicate an unspecified value. -
max_write_buffer_count number
-
max_write_buffer_size string
-
max_write_request_size string
-
read_poll_timeout string
A duration. Units can be
nanos
,micros
,ms
(milliseconds),s
(seconds),m
(minutes),h
(hours) andd
(days). Also accepts "0" without a unit and "-1" to indicate an unspecified value. -
remote_cluster string
curl \
-X PUT http://api.example.com/{index}/_ccr/follow \
-H "Content-Type: application/json" \
-d '{"leader_index":"string","max_outstanding_read_requests":42.0,"max_outstanding_write_requests":42.0,"max_read_request_operation_count":42.0,"max_read_request_size":"string","max_retry_delay":"string","max_write_buffer_count":42.0,"max_write_buffer_size":"string","max_write_request_operation_count":42.0,"max_write_request_size":"string","read_poll_timeout":"string","remote_cluster":"string"}'
{
"leader_index": "string",
"max_outstanding_read_requests": 42.0,
"max_outstanding_write_requests": 42.0,
"max_read_request_operation_count": 42.0,
"max_read_request_size": "string",
"max_retry_delay": "string",
"max_write_buffer_count": 42.0,
"max_write_buffer_size": "string",
"max_write_request_operation_count": 42.0,
"max_write_request_size": "string",
"read_poll_timeout": "string",
"remote_cluster": "string"
}
{
"follow_index_created": true,
"follow_index_shards_acked": true,
"index_following_started": true
}