Open
Description
When an index alias/data stream is replicated via CCR, the follower index needs to unfollow the leader index before executing actions that will remove the original index. As the docs recommend:
This action is triggered automatically by the rollover, shrink, and searchable snapshot actions when they are applied to follower indices.
Expected behaviour
The downsample action is also an action that removes the original index so the expected behaviour is that ILM would automatically unfollow.
Observed behaviour
ILM does not inject the unfollow action as you can see in the following snippet:
In other words we need to add the downsample action in this if
statement.