Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] stop replication fails to cleanly stop in case of very small indices #152

Closed
gbbafna opened this issue Sep 16, 2021 · 0 comments
Closed
Labels
backlog bug Something isn't working

Comments

@gbbafna
Copy link
Collaborator

gbbafna commented Sep 16, 2021

Describe the bug

there is a race condition where in , the index is left with write block even after replication is stopped

example logs

followCluster-1/logs/followCluster.log:[2021-09-16T13:57:22,262][INFO ][o.o.r.r.RemoteClusterRepository] [followCluster-1] Restore successful for [leader_index_yrwsia][0]


followCluster-1/logs/opensearch.stdout.log:[2021-09-16T13:57:23,514][INFO ][o.o.r.a.s.TransportStopIndexReplicationAction] [followCluster-1] Index[leader_index_yrwsia] is in restoring stage


followCluster-1/logs/followCluster.log:[2021-09-16T13:57:25,515][INFO ][o.o.r.t.i.IndexReplicationTask] [followCluster-1] [leader_index_yrwsia] Adding index block for replication

followCluster-1/logs/followCluster.log:[2021-09-16T13:57:25,514][INFO ][o.o.r.t.i.IndexReplicationTask] [followCluster-1] [leader_index_yrwsia] Starting shard tasks
followCluster-1/logs/followCluster.log:[2021-09-16T13:57:25,515][INFO ][o.o.r.t.i.IndexReplicationTask] [followCluster-1] [leader_index_yrwsia] Adding index block for replication
followCluster-1/logs/followCluster.log:[2021-09-16T13:57:27,512][INFO ][o.o.r.t.i.IndexReplicationTask] [followCluster-1] [leader_index_yrwsia] Cancelling index replication stop

Expected behavior

We should move all the logic from TransportStopReplication to IndexTask . This would take care of all such race conditions.

@gbbafna gbbafna added the bug Something isn't working label Sep 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants