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
Fixing this externally is likely not possible, as it is not possible to know when Start has finished initialization. and thus it is safe to call Stop. A solution could be to protect reads/writes from/to p.srv behind a mutex.
The text was updated successfully, but these errors were encountered:
A mutex seems a sensible solution. We just must be careful because Start is a blocking function, so we can't just defer releasing the lock. Instead we need to ensure it is always released before starting to listen for connections.
There seems to be a data race in the GRPC proxy tests, that only triggers under unknown circumstances:
The problem seems to be that the start function is run on a goroutine:
xk6-disruptor/pkg/agent/protocol/grpc/proxy_test.go
Lines 438 to 442 in daa6376
While at the same time,
Stop
is called on a deferred function:xk6-disruptor/pkg/agent/protocol/grpc/proxy_test.go
Lines 434 to 436 in daa6376
If the test ends prematurely, the
Stop
function attempts to read and then act uponp.srv
, whichStart
also modifies.xk6-disruptor/pkg/agent/protocol/grpc/proxy.go
Lines 122 to 127 in daa6376
Fixing this externally is likely not possible, as it is not possible to know when
Start
has finished initialization. and thus it is safe to callStop
. A solution could be to protect reads/writes from/top.srv
behind a mutex.The text was updated successfully, but these errors were encountered: