How to handle pre-existing indices using Auto-Follow

Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):

Describe the issue: If I am using Auto-Follow for replication, then, follower indices are created automatically based on “pattern” and “follower_index_pattern” specified in CCR rule. If for some reason CCR is stopped and then recreated between the same leader and follower clusters and using the same “pattern” and “follower_index_pattern”, then, what will happen to already existing follower indices. Will they be overwritten or skipped or will an error be raised by CCR plugin

Configuration:

Relevant Logs or Screenshots:

@farman What do you mean by CCR is stopped? Are you referring to deleting the replication rule (Auto-follow for cross-cluster replication | OpenSearch Documentation) or stopping/disconnecting the leader cluster?

I had no issues when I deleted auto-follow replication and recreated it. The replication was working, and new documents were added from the leader. The existing documents in the follower index remained.

I had a different result when I stopped the leader and waited 2 minutes before starting it again. The replication didn’t resume automatically either for auto-follow or individual replication.
I had to use _resume with the force_resume option. However, the indices were recreated, and all documents were fully resynced.

@farman I made a second attempt by stopping the leader cluster, and this time replication resumed automatically. However, if the leader cluster is down or replication is stopped/paused for more than 12 hours, you’ll need to force-resume, which will recreate all indices.

Thanks Pablo. I assume your second reply is the conclusive one.