Merge branch 'dev' into hugo-shipping-notice
This commit is contained in:
commit
472b530be3
397 files changed
+46450
-34171
No files matched your search
@@ -19,6 +19,8 @@ if TYPE_CHECKING:
|
||||
def _resolve_poll_seconds(ctx: JobContext) -> float:
|
||||
"""按队列配置读取轮询间隔。"""
|
||||
queues = ctx.extras.get('queues') or ['kb']
|
||||
if 'schedule' in queues and len(queues) == 1:
|
||||
return float(ctx.config.get('SCHEDULE_WORKER_POLL_SECONDS', 30))
|
||||
if 'shipping' in queues and 'kb' not in queues:
|
||||
return float(ctx.config.get('SHIPPING_NOTICE_WORKER_POLL_SECONDS', 2))
|
||||
return float(ctx.config.get('KB_WORKER_POLL_SECONDS', 2))
|
||||
|
||||
Reference in new issue
Block a user