原英文版地址: https://www.elastic.co/guide/en/elasticsearch/reference/7.7/ccr-get-auto-follow-pattern.html, 原文档版权归 www.elastic.co 所有
本地英文版地址: ../en/ccr-get-auto-follow-pattern.html
本地英文版地址: ../en/ccr-get-auto-follow-pattern.html
重要: 此版本不会发布额外的bug修复或文档更新。最新信息请参考 当前版本文档。
Get auto-follow pattern APIedit
Get auto-follow patterns.
Prerequisitesedit
-
If the Elasticsearch security features are enabled, you must have
manage_ccr
cluster privileges on the cluster that contains the follower index. For more information, see Security privileges.
Descriptionedit
This API gets configured auto-follow patterns. This API will return the specified auto-follow pattern collection.
Path parametersedit
-
<auto_follow_pattern_name>
- (Optional, string) Specifies the auto-follow pattern collection that you want to retrieve. If you do not specify a name, the API returns information for all collections.
Examplesedit
This example retrieves information about an auto-follow pattern collection
named my_auto_follow_pattern
:
GET /_ccr/auto_follow/my_auto_follow_pattern
The API returns the following result:
{ "patterns": [ { "name": "my_auto_follow_pattern", "pattern": { "active": true, "remote_cluster" : "remote_cluster", "leader_index_patterns" : [ "leader_index*" ], "follow_index_pattern" : "{{leader_index}}-follower" } } ] }