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
RedisClient is an expensive resource. It holds a set of netty's EventLoopGroup's that use multiple threads. Reuse this instance as much as possible or share a ClientResources instance amongst multiple client instances.
RedisRateLimiterFactory makes it difficult to share a single RedisClient, because its close() method closes the client. (That is, it effectively "takes ownership" of the client.)
Taking a RedisClient also makes it incompatible with connection pooling, as typically one does not have visibility to the RedisClient itself outside of the pool's construction.
Given that RedisRateLimiterFactory only uses a single connection, could an additional constructor that takes a StatefulRedisConnection<String, String> be added?
The text was updated successfully, but these errors were encountered:
The
RedisClient
docs say:RedisRateLimiterFactory
makes it difficult to share a singleRedisClient
, because itsclose()
method closes the client. (That is, it effectively "takes ownership" of the client.)Taking a
RedisClient
also makes it incompatible with connection pooling, as typically one does not have visibility to theRedisClient
itself outside of the pool's construction.Given that
RedisRateLimiterFactory
only uses a single connection, could an additional constructor that takes aStatefulRedisConnection<String, String>
be added?The text was updated successfully, but these errors were encountered: