[C#] How to set the Redis Server pool size with the CacheManager ?
I got an error with high concurrency: No connection is available to service this operation: HMGET , How to set the connection pool size?
No connection is available to service this operation: HMGET U
at StackExchange.Redis.ConnectionMultiplexer.ExecuteSyncImpl[T](Message message, ResultProcessor`1 processor, ServerEndPoint server)
at StackExchange.Redis.RedisBase.ExecuteSync[T](Message message, ResultProcessor`1 processor, ServerEndPoint server)
at StackExchange.Redis.RedisDatabase.HashGet(RedisKey key, RedisValue[] hashFields, CommandFlags flags)
at CacheManager.Redis.RedisCacheHandle`1.<>c__DisplayClass25_0.<GetCacheItemInternal>b__0()
at CacheManager.Redis.RetryHelper.Retry[T](Func`1 retryme, Int32 timeOut, Int32 retries)
at CacheManager.Redis.RedisCacheHandle`1.Retry[T](Func`1 retryme)
at CacheManager.Redis.RedisCacheHandle`1.GetCacheItemInternal(String key, String region)
at CacheManager.Redis.RedisCacheHandle`1.GetCacheItemInternal(String key)
at CacheManager.Core.Internal.BaseCache`1.GetCacheItem(String key)
at CacheManager.Core.BaseCacheManager`1.GetCacheItemInternal(String key, String region)
at CacheManager.Core.BaseCacheManager`1.GetCacheItemInternal(String key)
at CacheManager.Core.Internal.BaseCache`1.GetCacheItem(String key)
at CacheManager.Core.Internal.BaseCache`1.Get(String key)
at CacheManager.Core.Internal.BaseCache`1.Get[TOut](String key)
=======================
var cache = CacheFactory.Build("RuntimeCache", settings =>
{
settings.WithSystemRuntimeCacheHandle("RuntimeCache")
.WithExpiration(ExpirationMode.Sliding, TimeSpan.FromMinutes(10))
.And
.WithRedisConfiguration("RedisCache", config =>
{
config.WithAllowAdmin()
.WithDatabase(1)
.WithPassword(password)
.WithEndpoint(host, port);
})
.WithMaxRetries(100)
.WithRetryTimeout(50)
.WithRedisBackPlate("RedisCache")
.WithRedisCacheHandle("RedisCache", true)
.WithExpiration(ExpirationMode.Sliding, TimeSpan.FromMinutes(30));
});