Get cross-cluster replication stats
- GET /_ccr/stats
This API returns stats about auto-following and the same shard-level stats as the get follower stats API.
- Cluster privileges:
monitor
Query Parameters
-
master_timeoutstring Duration · default: 30s The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to
-1to indicate that the request should never timeout.-
timeoutstring Duration · default: 30s The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.
Response
-
auto_follow_statsAutoFollowStatsrequired -
Statistics for the auto-follow coordinator.
-
auto_followed_clustersAutoFollowedClusterrequired -
cluster_namestring Namerequired -
last_seen_metadata_versionnumber VersionNumberrequired -
time_since_last_check_millisDurationValueUnitMillisrequired -
number_of_failed_follow_indicesnumberrequired -
The number of indices that the auto-follow coordinator failed to automatically follow. The causes of recent failures are captured in the logs of the elected master node and in the
auto_follow_stats.recent_auto_follow_errorsfield. -
number_of_failed_remote_cluster_state_requestsnumberrequired -
The number of times that the auto-follow coordinator failed to retrieve the cluster state from a remote cluster registered in a collection of auto-follow patterns.
-
number_of_successful_follow_indicesnumberrequired -
The number of indices that the auto-follow coordinator successfully followed.
-
recent_auto_follow_errorsErrorCauserequired -
An array of objects representing failures by the auto-follow coordinator.
-
typestringrequired -
The type of error
-
reasonstringnullable -
A human-readable explanation of the error, in English.
-
stack_tracestring -
The server stack trace. Present only if the
error_trace=trueparameter was sent with the request. -
caused_byErrorCause -
root_causeErrorCause -
suppressedErrorCause -
follow_statsFollowStatsrequired -
Shard-level statistics for follower indices.
-
indicesFollowIndexStatsrequired -
indexstring IndexNamerequired -
The name of the follower index.
-
shardsShardStatsrequired -
An array of shard-level following task statistics.
-
bytes_readnumberrequired -
The total of transferred bytes read from the leader. This is only an estimate and does not account for compression if enabled.
-
failed_read_requestsnumberrequired -
The number of failed reads.
-
failed_write_requestsnumberrequired -
The number of failed bulk write requests on the follower.
-
fatal_exceptionErrorCause -
typestringrequired -
The type of error
-
reasonstringnullable -
A human-readable explanation of the error, in English.
-
stack_tracestring -
The server stack trace. Present only if the
error_trace=trueparameter was sent with the request. -
caused_byErrorCause -
root_causeErrorCause -
suppressedErrorCause -
follower_aliases_versionnumber VersionNumberrequired -
The index aliases version the follower is synced up to.
-
follower_global_checkpointnumberrequired -
The current global checkpoint on the follower. The difference between the
leader_global_checkpointand thefollower_global_checkpointis an indication of how much the follower is lagging the leader. -
follower_indexstringrequired -
The name of the follower index.
-
follower_mapping_versionnumber VersionNumberrequired -
The mapping version the follower is synced up to.
-
follower_max_seq_nonumber SequenceNumberrequired -
The current maximum sequence number on the follower.
-
follower_settings_versionnumber VersionNumberrequired -
The index settings version the follower is synced up to.
-
last_requested_seq_nonumber SequenceNumberrequired -
The starting sequence number of the last batch of operations requested from the leader.
-
leader_global_checkpointnumberrequired -
The current global checkpoint on the leader known to the follower task.
-
leader_indexstringrequired -
The name of the index in the leader cluster being followed.
-
leader_max_seq_nonumber SequenceNumberrequired -
The current maximum sequence number on the leader known to the follower task.
-
operations_readnumberrequired -
The total number of operations read from the leader.
-
operations_writtennumberrequired -
The number of operations written on the follower.
-
outstanding_read_requestsnumberrequired -
The number of active read requests from the follower.
-
outstanding_write_requestsnumberrequired -
The number of active bulk write requests on the follower.
-
read_exceptionsReadExceptionrequired -
An array of objects representing failed reads.
-
exceptionErrorCauserequired -
The exception that caused the read to fail.
-
typestringrequired -
The type of error
-
reasonstringnullable -
A human-readable explanation of the error, in English.
-
stack_tracestring -
The server stack trace. Present only if the
error_trace=trueparameter was sent with the request. -
caused_byErrorCause -
root_causeErrorCause -
suppressedErrorCause -
from_seq_nonumber SequenceNumberrequired -
The starting sequence number of the batch requested from the leader.
-
retriesnumberrequired -
The number of times the batch has been retried.
-
remote_clusterstringrequired -
The remote cluster containing the leader index.
-
shard_idnumberrequired -
The numerical shard ID, with values from 0 to one less than the number of replicas.
-
successful_read_requestsnumberrequired -
The number of successful fetches.
-
successful_write_requestsnumberrequired -
The number of bulk write requests run on the follower.
-
time_since_last_readstring Duration -
time_since_last_read_millisDurationValueUnitMillisrequired -
The number of milliseconds since a read request was sent to the leader. When the follower is caught up to the leader, this number will increase up to the configured
read_poll_timeoutat which point another read request will be sent to the leader. -
total_read_remote_exec_timestring Duration -
total_read_remote_exec_time_millisDurationValueUnitMillisrequired -
The total time reads spent running on the remote cluster.
-
total_read_timestring Duration -
total_read_time_millisDurationValueUnitMillisrequired -
The total time reads were outstanding, measured from the time a read was sent to the leader to the time a reply was returned to the follower.
-
total_write_timestring Duration -
total_write_time_millisDurationValueUnitMillisrequired -
The total time spent writing on the follower.
-
write_buffer_operation_countnumberrequired -
The number of write operations queued on the follower.
-
write_buffer_size_in_bytesnumber | string ByteSizerequired -
The total number of bytes of operations currently queued for writing.