Commit e7e11bf
authored
fix(map): Emit valueChanged event when there are pending local ops after remote clear (#26010)
When a remote clear operation is received while there are pending local
set operations, the map emits a "clear" event but the map still contains
keys. This made the clear event unreliable as an indicator of map state,
requiring the oracle to re-read all keys after every clear event.
This change adds functionality to emit `valueChanged` event for keys
which are deleted during remote clears. This way the customers would
have to just focus on the `valueChanged` event and not `clear` event for
remote ops.
[ADO#48665](https://dev.azure.com/fluidframework/internal/_workitems/edit/48665)
Follow-up:
[ADO#55457](https://dev.azure.com/fluidframework/internal/_workitems/edit/55457)1 parent 818db6b commit e7e11bf
File tree
3 files changed
+39
-10
lines changed- packages/dds/map/src
- test
- mocha
3 files changed
+39
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
685 | 685 | | |
686 | 686 | | |
687 | 687 | | |
688 | | - | |
689 | 688 | | |
| 689 | + | |
690 | 690 | | |
691 | 691 | | |
692 | 692 | | |
| |||
695 | 695 | | |
696 | 696 | | |
697 | 697 | | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
698 | 713 | | |
699 | 714 | | |
700 | 715 | | |
701 | 716 | | |
| 717 | + | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
702 | 727 | | |
703 | 728 | | |
704 | 729 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
| 45 | + | |
| 46 | + | |
52 | 47 | | |
53 | 48 | | |
54 | 49 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
517 | 517 | | |
518 | 518 | | |
519 | 519 | | |
520 | | - | |
| 520 | + | |
| 521 | + | |
521 | 522 | | |
522 | 523 | | |
523 | 524 | | |
524 | 525 | | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
525 | 532 | | |
526 | 533 | | |
527 | 534 | | |
528 | 535 | | |
529 | 536 | | |
530 | 537 | | |
531 | | - | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
532 | 541 | | |
533 | 542 | | |
534 | 543 | | |
| |||
0 commit comments