Repository navigation
De-flake ORMultiValueDictionary_WithValueDeltas_LargeDataSet: replicate with WriteLocal and poll the replicas - #8611
Merged
Aaronontheweb merged 1 commit intoSep 23, 2026
Conversation
…h WriteLocal and poll the replicas SetItems clears and re-adds every element, so each update ships the full 20k-element set. Under WriteMajority the write aggregator resends that full state to the primary and secondary acks every Timeout/5, and a hop already took ~2.5s under CI load, so each write fanned out roughly three full-state payloads across three ActorSystems sharing one thread pool - causing UpdateTimeout flakiness on 2-vCPU CI agents. Two earlier fixes (akkadotnet#5686, akkadotnet#7899) just raised the timeout. This switches the updates to WriteLocal and polls each replica's local copy until it converges, avoiding WriteMajority's resend amplification while still catching the akkadotnet#5663 quadratic SetItems/merge regression the test guards.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ReplicatorSpecs.ORMultiValueDictionary_WithValueDeltas_LargeDataSetfailed on the AOT stack's CI (#8604, Windows unit tests) withUpdateTimeouton its secondWriteMajorityupdate. The failure has nothing to do with that PR. This is the third de-flake of this test. The first two (#5686, #7899) raised the timeout; this one removes the cause.Cause
ORMultiValueDictionary.SetItemsclears and re-adds every element (the same as JVMORMultiMap.put). Each write in this test ships the full 20,000-element set, delta included.WriteMajority,ReadWriteAggregatorresends the full state to the primary and secondary afterTimeout/5, which is 2 s here. On a 2-vCPU agent one hop already took about 2.5 s. So each write sent roughly three full payloads between three in-process ActorSystems sharing one thread pool.WriteAcks arriving 5–9 s after the aggregator had timed out.WriteMajority; the flapping was a symptom of the CPU load.Change
WriteLocal.GetwithReadLocal, insideAwaitAssertAsync) until the entries equal the expected set, with aDilated(30s)bound. The data still replicates across all three nodes, through delta propagation (every 400 ms) and gossip.ExpectMsg<Changed>calls, each of which blocked a pool thread for up to 10 s, are gone.The test still catches the #5663 quadratic
SetItems/merge regression it was written for. It no longer coversWriteMajoritywith a 20,000-element payload; the rest ofReplicatorSpecsstill coversWriteMajority.Verification (local)
ReplicatorSpecsclass passes, 7/7.