是否可以设置ES Index Lifecycle Management来删除基于其中包含日期的名称的索引,即my_index_yyyy_MM_dd
,而不是索引年龄?
不幸的是,没有 - ILM只支持基于年龄的相变,据我所知,这是由指数creation_date
决定的。
为了支持模式匹配删除,我建议使用Curator(delete_indices
)的https://www.elastic.co/guide/en/elasticsearch/client/curator/current/delete_indices.html动作和适合您的用例的过滤器。