Commit 6c9687b
authored
This fixes missing to marking shard snapshots as failures when
multiple data-nodes are lost during the snapshot process or
shard snapshot failures have occured before a node left the cluster.
The problem was that we were simply not adding any shard entries for completed
shards on node-left events. This has no effect for a successful shard, but
for a failed shard would lead to that shard not being marked as failed during
snapshot finalization. Fixed by corectly keeping track of all previous completed
shard states as well in this case.
Also, added an assertion that without this fix would trip on almost every run of the
resiliency tests and adjusted the serialization of SnapshotsInProgress.Entry so
we have a proper assertion message.
Closes #47550
1 parent 29c1424 commit 6c9687b
File tree
2 files changed
+56
-43
lines changed- server/src/main/java/org/elasticsearch
- cluster
- snapshots
2 files changed
+56
-43
lines changedLines changed: 47 additions & 39 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
28 | 29 | | |
29 | 30 | | |
30 | 31 | | |
| |||
76 | 77 | | |
77 | 78 | | |
78 | 79 | | |
79 | | - | |
| 80 | + | |
80 | 81 | | |
81 | 82 | | |
82 | 83 | | |
| |||
210 | 211 | | |
211 | 212 | | |
212 | 213 | | |
213 | | - | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
214 | 258 | | |
215 | 259 | | |
216 | 260 | | |
| |||
507 | 551 | | |
508 | 552 | | |
509 | 553 | | |
510 | | - | |
| 554 | + | |
511 | 555 | | |
512 | 556 | | |
513 | 557 | | |
514 | 558 | | |
515 | 559 | | |
516 | | - | |
517 | | - | |
518 | | - | |
519 | | - | |
520 | | - | |
521 | | - | |
522 | | - | |
523 | | - | |
524 | | - | |
525 | | - | |
526 | | - | |
527 | | - | |
528 | | - | |
529 | | - | |
530 | | - | |
531 | | - | |
532 | | - | |
533 | | - | |
534 | | - | |
535 | | - | |
536 | | - | |
537 | | - | |
538 | | - | |
539 | | - | |
540 | | - | |
541 | | - | |
542 | | - | |
543 | | - | |
544 | | - | |
545 | | - | |
546 | | - | |
547 | | - | |
548 | | - | |
549 | | - | |
550 | | - | |
551 | | - | |
552 | 560 | | |
553 | 561 | | |
554 | 562 | | |
| |||
Lines changed: 9 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
764 | 764 | | |
765 | 765 | | |
766 | 766 | | |
767 | | - | |
| 767 | + | |
| 768 | + | |
768 | 769 | | |
769 | 770 | | |
770 | | - | |
| 771 | + | |
771 | 772 | | |
772 | 773 | | |
773 | 774 | | |
774 | 775 | | |
775 | | - | |
776 | | - | |
| 776 | + | |
| 777 | + | |
777 | 778 | | |
778 | 779 | | |
| 780 | + | |
| 781 | + | |
779 | 782 | | |
780 | 783 | | |
781 | 784 | | |
| |||
807 | 810 | | |
808 | 811 | | |
809 | 812 | | |
| 813 | + | |
| 814 | + | |
810 | 815 | | |
811 | 816 | | |
812 | 817 | | |
| |||
0 commit comments