You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm running in simulation mode (though I've hit a similar crash in capture mode too). The simulation is stateful. Here's the error message: fatal error: concurrent map read and map write.
It seems like access to the State map isn't synchronized.
Not sure if this is a good idea or not... but I just added some basic locking using a RWMutex on State. This seemed to resolve the crashes I was seeing (in simulation and capture). Here's a diff master...john4744:sync-state
If this sounds like the right approach, I'll submit a PR.
What you have said makes complete sense and I think the approach you have taken looks right. My only niggle with it is in core/matching/strongest_match_strategy.go you create a copy of the state while locking and unlocking it, but you do not do the same in core/matching/state_matcher.go. If you could update the state_matcher.go file to use a copy of the state, I think this would be just that little bit better.
Would definitely love a PR though, as it looks great and looks like something we should definitely solve.
I'm running in simulation mode (though I've hit a similar crash in capture mode too). The simulation is stateful. Here's the error message:
fatal error: concurrent map read and map write
.It seems like access to the State map isn't synchronized.
Here is the full dump
The text was updated successfully, but these errors were encountered: