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
Fleet version (Head to the "My account" page in the Fleet UI or run fleetctl version): 3.10.1
Fleet tier (Are you using the free (Fleet Core) or paid (Fleet Basic) tier?): free
User role (Which role are you assigned in Fleet? (Admin, Maintainer, or Observer)):
3 roles are introduced in Fleet 4.0.0. If you're using a prior version of Fleet or don't know your assigned role, please feel free to leave this item blank.
🧑💻 Expected behavior
As Redigo's documentation describe:
Connections support one concurrent caller to the Receive method and one concurrent caller to the Send and Flush methods. No other concurrency is supported including concurrent calls to the Do method.
For full concurrent access to Redis, use the thread-safe Pool to get, use and release a connection from within a goroutine. Connections returned from a Pool have the concurrency restrictions described in the previous paragraph.
profile001.pdf
Actually,My fleet server bumps into a redis max connections issue , and the attached file is the goroutine debug pdf
the detailed description as the other issue I report #1541
tony21177
changed the title
Wrongly used redigo for that it does not support concurrently Receive and Close
Question about using redigo for that it does not support concurrently Receive and Close
Aug 3, 2021
Hi @tony21177, the connection retrieving from the pool is thread safe. But what I believe that means is that the retrieving is thread safe, not the usage. Which is why it says "use and release a connection from within a goroutine".
Thank you for reporting this, I'll have a PR soon.
Fleet version (Head to the "My account" page in the Fleet UI or run
fleetctl version
): 3.10.1Fleet tier (Are you using the free (Fleet Core) or paid (Fleet Basic) tier?): free
User role (Which role are you assigned in Fleet? (Admin, Maintainer, or Observer)):
🧑💻 Expected behavior
As Redigo's documentation describe:
https://pkg.go.dev/github.com/garyburd/redigo/redis#hdr-Concurrency
💥 Actual behavior
https://github.com/fleetdm/fleet/blob/main/server/pubsub/redis_query_results.go#L163
redis_query_results.go#L163
the goroutine use the redis connection to Receive
https://github.com/fleetdm/fleet/blob/main/server/pubsub/redis_query_results.go#L167
redis_query_results.go#L167
but another goroutine use the same connection to Close.
Doesn't it violate the redigo not supporting concurrency limitation?
The text was updated successfully, but these errors were encountered: