Skip to content

[FIXED] Concurrent map iter/write for WQ stream unique consumer partition#7708

Merged
neilalexander merged 1 commit intomainfrom
maurice/wq-partition-fatal
Jan 8, 2026
Merged

[FIXED] Concurrent map iter/write for WQ stream unique consumer partition#7708
neilalexander merged 1 commit intomainfrom
maurice/wq-partition-fatal

Conversation

@MauriceVanVeen
Copy link
Copy Markdown
Member

There's a fatal error: concurrent map iteration and map write when ranging over the mset.consumers in mset.partitionUnique.

The stream lock must be held when calling mset.partitionUnique. The consumer read lock must also be held when reading and iterating over o.subjf.

Resolves #7707

Signed-off-by: Maurice van Veen github@mauricevanveen.com

Signed-off-by: Maurice van Veen <github@mauricevanveen.com>
@MauriceVanVeen MauriceVanVeen requested a review from a team as a code owner January 8, 2026 08:05
Copy link
Copy Markdown
Contributor

@sciascid sciascid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@neilalexander neilalexander merged commit 3a90a2d into main Jan 8, 2026
69 of 70 checks passed
@neilalexander neilalexander deleted the maurice/wq-partition-fatal branch January 8, 2026 09:02
neilalexander added a commit that referenced this pull request Jan 15, 2026
Includes the following:

- #7704
- #7708
- #7710
- #7709
- #7712
- #7716
- #7720
- #7721
- #7723
- #7728

Signed-off-by: Neil Twigg <neil@nats.io>
neilalexander added a commit that referenced this pull request Jan 15, 2026
Includes the following:

- #7704
- #7708
- #7710
- #7711
- #7709
- #7712
- #7716
- #7720
- #7721
- #7723
- #7728

Signed-off-by: Neil Twigg <neil@nats.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fatal error: concurrent map iteration and map write

3 participants