Fix/WC init race condition #261
No reviewers
Labels
No labels
P0
P1
P2
P3
badger
frostfs-adm
frostfs-cli
frostfs-ir
frostfs-lens
frostfs-node
good first issue
triage
Infrastructure
blocked
bug
config
discussion
documentation
duplicate
enhancement
go
help wanted
internal
invalid
kludge
observability
perfomance
question
refactoring
wontfix
No milestone
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: TrueCloudLab/frostfs-node#261
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "fix/races-in-WC"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Do not use WC's internals in the initialization routines without mode
protection. WC should be able to change its mode even if the initialization
is not finished yet.
Signed-off-by: Pavel Karpy p.karpy@yadro.com
Was hard to reproduce (1/10, i guess). Not a perfect solution but the perfect lies somewhere near WC refactor i guess (without cache, complex async initialization etc).
@ -89,1 +89,4 @@
c.modeMtx.RLock()
_, _ = c.fsTree.Iterate(prm)
c.modeMtx.RUnlock()
Why not
defer
?wanted it to unlock as fast as possible, without logging and other (possible in future) things. changed to be deferred
1d4601f2f7
tof87f44725a