-
Notifications
You must be signed in to change notification settings - Fork 6
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
fix: stale participant concurrent modification exeption [WPB-15340] 🍒 #3280
Conversation
…3278) * fix: stale participant concurrent modification exeption * revert private variable
|
|
Branch | fix/stale-particpant-crash-cherry-pick |
Testbed | ubuntu-latest |
⚠️ WARNING: No Threshold found!Without a Threshold, no Alerts will ever be generated.
Click here to create a new Threshold
For more information, see the Threshold documentation.
To only post results if a Threshold exists, set the--ci-only-thresholds
flag.
Click to view all benchmark results
Benchmark | Latency | microseconds (µs) |
---|---|---|
com.wire.kalium.benchmarks.logic.CoreLogicBenchmark.createObjectInFiles | 📈 view plot | 680.46 |
com.wire.kalium.benchmarks.logic.CoreLogicBenchmark.createObjectInMemory | 📈 view plot | 351,595.74 |
com.wire.kalium.benchmarks.persistence.MessagesNoPragmaTuneBenchmark.messageInsertionBenchmark | 📈 view plot | 1,339,934.17 |
com.wire.kalium.benchmarks.persistence.MessagesNoPragmaTuneBenchmark.queryMessagesBenchmark | 📈 view plot | 22,090.68 |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #3280 +/- ##
===========================================
- Coverage 50.84% 50.84% -0.01%
===========================================
Files 1607 1607
Lines 58052 58054 +2
Branches 5203 5203
===========================================
+ Hits 29514 29515 +1
- Misses 26521 26522 +1
Partials 2017 2017 see 4 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
Datadog ReportBranch report: ✅ 0 Failed, 3405 Passed, 108 Skipped, 59.32s Total Time |
This PR was automatically cherry-picked based on the following PR:
Original PR description:
PR Submission Checklist for internal contributors
The PR Title
SQPIT-764
The PR Description
What's new in this PR?
Issues
leaveMlsConference()
, which was triggered when multiple threads attempted to modifystaleParticipantJobs
simultaneously.Causes
staleParticipantJobs
is aConcurrentMutableMap
, but previous implementations did not ensure thread-safe modifications when iterating over and modifying the collection at the same time.hasEstablishedAudio = false
), a delayed coroutine was scheduled to remove them from the MLS group.leaveMlsConference()
iterated overstaleParticipantJobs
, removing and canceling jobs. However,updateCallParticipants()
could simultaneously modify this map, leading to aConcurrentModificationException
.Solutions
leaveMlsConference()
to use theblock {}
method fromConcurrentMutableMap
, ensuring that all modifications are performed in a thread-safe manner.staleParticipantJobs
safely.