net api中的azure redis超时

wz8daaqr  于 2021-06-09  发布在  Redis
关注(0)|答案(1)|浏览(480)

我有asp net v4.6.1和stackexchange.redis v2.0.61,自从redis实现以来,我总是以随机的方式出现相同的错误,下面是一些错误日志,如果有人能帮忙的话,我遵循官方文档/microsoft论坛提供的步骤,有助于减少错误数量和更改线程池。

Timeout performing GET (2000ms), next: GET key, inst: 0, qu: 0, qs: 9, aw: False, rs: ReadAsync, ws: Idle, in: 0, serverEndpoint: Unspecified/{myserver}:6380, mgr: 10 of 10 available, clientName: {myclient}, IOCP: (Busy=0,Free=1000,Min=4,Max=1000), WORKER: (Busy=38,Free=8153,Min=4,Max=8191), v: 2.0.601.3402 (Please take a look at this article for some common client-side issues that can cause timeouts: https://stackexchange.github.io/StackExchange.Redis/Timeouts)

.

Timeout performing GET (2000ms), next: GET key1, inst: 1, qu: 0, qs: 6, aw: False, rs: ReadAsync, ws: Idle, in: 34344, serverEndpoint: Unspecified/{myserver}:6380, mgr: 10 of 10 available, clientName: {myclient}, IOCP: (Busy=0,Free=1000,Min=4,Max=1000), WORKER: (Busy=39,Free=8152,Min=4,Max=8191), v: 2.0.601.3402 (Please take a look at this article for some common client-side issues that can cause timeouts: https://stackexchange.github.io/StackExchange.Redis/Timeouts)

.

Timeout performing GET (2000ms), next: GET key2, inst: 12, qu: 0, qs: 10, aw: False, rs: ReadAsync, ws: Idle, in: 10159, serverEndpoint: Unspecified/{myserver}:6380, mgr: 10 of 10 available, clientName: {myclient}, IOCP: (Busy=0,Free=1000,Min=4,Max=1000), WORKER: (Busy=25,Free=8166,Min=4,Max=8191), v: 2.0.601.3402 (Please take a look at this article for some common client-side issues that can cause timeouts: https://stackexchange.github.io/StackExchange.Redis/Timeouts)

azure统计:
内存105mo~/cpu:0%~25%

谢谢您;

yb3bgrhw

yb3bgrhw1#

看起来您在客户端计算机上遇到请求/响应的备份,这会导致后面的请求超时。这可能是由于线程不足或昂贵的响应处理逻辑造成的。
在所有三个例外中 WORKER 部分显示 Busy 线程数大于 Min 计算.net在 ThreadPool . 你应该调整你的身体 ThreadPool 设置以增加最小计数或了解如何减少客户端中的工作线程数,使其小于 Min 有两个例外, in: number 显示 number 大于0。这表示响应流中有字节等待客户端应用程序读取。这可能是由于客户端应用程序发送请求的速度比处理其响应的速度快。慢响应处理通常表示正在使用响应值执行昂贵的逻辑,尽管这可能会由于线程不足而进一步减慢。
https://stackexchange.github.io/stackexchange.redis/timeouts
https://docs.microsoft.com/azure/azure-cache-for-redis/cache-troubleshoot-client#traffic-爆裂

相关问题