Skip to content

Auto follow patterns with 'follow_index_pattern' fail to replicate data streams #81751

@martijnvg

Description

@martijnvg

A auto follow patterns with a rename pattern fails to replicate a data stream:

{
     "pattern": {
        "remote_cluster": "leader_cluser",
        "leader_index_patterns": ["*"],
        "follow_index_pattern": "{{leader_index}}_copy"
    }
}

The follow error can then occur:

java.lang.IllegalArgumentException: a backing index name in the local and remote cluster must remain the same

The problem is that only the backing index being replicated is renamed, but not the data stream. This then fails internal validation that checks that name of backing indices contains the name of the data stream.

Maybe we can drop this validation (since there are cases when we already allow for this, for example when migrating an alias to data stream) or we should also rename the data stream when this happens (so that naming is what the validation logic expect it to be).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions