feat(shipping): 新增货运订单处理相关作业及配套配置

- 为测试和生产环境添加RPA工作器告警启用配置项
- 新增多个货运订单处理专用的作业处理器
- 更新作业类型枚举与货运队列的消费配置
- 重构并补全货运相关模型的导入声明
This commit is contained in:
hugo committed 2026-08-11 15:39:02 +08:00
1 parent 472b530be3
commit 4587b56900
6 files changed
+1627 -43

No files matched your search

+19 -1
View File
@@ -5,4 +5,22 @@ backend/app/jobs/handlers/__init__.py
逻辑:Wave 2 起在 worker 启动前 import 本包。
"""
from app.jobs.handlers import file_check_run, kb_clean, kb_dify_sync, procurement_contract_review, schedule_run, shipping_notice_parse, shipping_notice_run, wecom_directory_sync # noqa: F401
from app.jobs.handlers import (
file_check_run,
kb_clean,
kb_dify_sync,
procurement_contract_review,
schedule_run,
shipping_auto_progress,
shipping_document_layout,
shipping_line_auto_fulfill,
shipping_notice_parse,
shipping_notice_run,
shipping_order_extraction,
shipping_post_ot_wave_progress,
shipping_process_gate,
shipping_review_revalidate_progress,
shipping_stp_auto_create,
shipping_xfa_ocr_automark,
wecom_directory_sync,
) # noqa: F401
+16 -1
View File
@@ -16,6 +16,15 @@ class JobType(StrEnum):
KB_DIFY_SYNC = 'kb_dify_sync'
SHIPPING_NOTICE_RUN = 'shipping_notice_run'
SHIPPING_NOTICE_PARSE = 'shipping_notice_parse'
SHIPPING_ORDER_EXTRACTION = 'shipping_order_extraction'
SHIPPING_DOCUMENT_LAYOUT = 'shipping_document_layout'
SHIPPING_PROCESS_GATE = 'shipping_process_gate'
SHIPPING_AUTO_PROGRESS = 'shipping_auto_progress'
SHIPPING_LINE_AUTO_FULFILL = 'shipping_line_auto_fulfill'
SHIPPING_POST_OT_WAVE_PROGRESS = 'shipping_post_ot_wave_progress'
SHIPPING_REVIEW_REVALIDATE_PROGRESS = 'shipping_review_revalidate_progress'
SHIPPING_STP_AUTO_CREATE = 'shipping_stp_auto_create'
SHIPPING_XFA_OCR_AUTOMARK = 'shipping_xfa_ocr_automark'
SCHEDULE_RUN = 'schedule_run'
FILE_CHECK_RUN = 'file_check_run'
WECOM_DIRECTORY_SYNC = 'wecom_directory_sync'
@@ -50,7 +59,13 @@ _HANDLER_TO_KB_JOB_TYPE: dict[JobType, str] = {
# worker --queues 参数 → 可消费的 KbJob.job_type 集合
QUEUE_KB_JOB_TYPES: dict[str, frozenset[str]] = {
'kb': frozenset({'clean', 'path_upload', 'sync_dify'}),
'shipping': frozenset({'shipping_notice_run', 'shipping_notice_parse'}),
'shipping': frozenset({
'shipping_notice_run', 'shipping_notice_parse', 'shipping_order_extraction',
'shipping_document_layout', 'shipping_process_gate', 'shipping_auto_progress',
'shipping_line_auto_fulfill', 'shipping_post_ot_wave_progress',
'shipping_review_revalidate_progress', 'shipping_stp_auto_create',
'shipping_xfa_ocr_automark',
}),
'contract': frozenset({'procurement_contract_review'}),
'schedule': frozenset({'schedule_run'}),
}