针对动态后端的任务经常失败,无声无息 [英] Tasks targeted at dynamic backend fail frequently, silently

查看:84
本文介绍了针对动态后端的任务经常失败,无声无息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经将某些任务转换为在动态后端上运行。



这些任务正在悄悄失败[没有记录错误,没有重试,没有任何内容]〜20%时间(分钟:10%,最大:60%,样本:大,长期)。将任务从后端切换回来可以恢复重试,并将故障率恢复到〜0%。

有什么想法?

解决方案

将它转换为后端会加剧问题,但问题不在这里。



我指定了一个 task_retry_limit ,队列是一个推送队列。通过后端指定实例的数量。 (我相信你可以通过快速增加请求来将这个问题复制到一个大数字中)。

任务失败 503:实例不可用直到它们碰到 task_retry_limit 。这在任务队列中暂时可见,但不会显示在日志中。



我应该使用拉队列。即使我的用例很愚蠢,我可能会因为多个 503:实例不可用而记录一些任务,因此它不会显示为虚幻任务。 / p>

I had converted some tasks to run on a dynamic backend.

The tasks are failing silently [no logged error, no retry, nothing] ~20% of the time (min:10%, max:60%, sample:large, long term). Switching the task away from the backend restores retries and gets the failure rate back to ~0%.

Any ideas?

解决方案

Converting it to a backend exacerbated the problem but wasn't the problem.

I had specified a task_retry_limit and the queue was a push queue. With a backend the number of instances is specified. (I believe you can replicate this issue on the frontend by ramping up requests rapidly, to a big number).

Tasks were failing 503: Instance Unavailable until they hit the task_retry_limit. This is visible temporarily in Task Queues, but will not show up in Logs.

I should be using pull queues. Even if my use case was stupid I'd probably +1 a task dying due to multiple 503: Instance Unavailable logging something so it doesn't appear like a phantom task.

这篇关于针对动态后端的任务经常失败,无声无息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆