perf(api): parallelize priority live readbacks
All checks were successful
CD Pipeline / workflow-shape (push) Successful in 0s
CD Pipeline / cancel-stale-cd (push) Has been skipped
CD Pipeline / tests (push) Successful in 1m8s
CD Pipeline / build-and-deploy (push) Successful in 5m3s
CD Pipeline / post-deploy-checks (push) Successful in 2m58s

This commit is contained in:
ogt
2026-07-10 21:57:24 +08:00
parent 7b08df3bdb
commit 14108c006f

View File

@@ -1227,11 +1227,23 @@ async def _build_awoooi_priority_work_order_readback_with_live_overlays() -> dic
stockplatform_runtime,
reboot_slo,
autonomous_runtime_control,
harbor_recovery,
log_executor,
controlled_cd_lane_metrics,
post_write_verifier,
consumer_readback,
telegram_alert_context_verifier,
) = await asyncio.gather(
asyncio.to_thread(load_latest_gitea_repo_bundle_backup_readback),
asyncio.to_thread(load_latest_stockplatform_public_api_runtime_readback),
asyncio.to_thread(load_latest_reboot_auto_recovery_slo_scorecard),
build_ai_agent_autonomous_runtime_control_with_live_readback(),
asyncio.to_thread(load_latest_harbor_registry_controlled_recovery_preflight),
asyncio.to_thread(load_latest_ai_agent_log_controlled_writeback_executor_readback),
asyncio.to_thread(load_controlled_cd_lane_live_metric_readback),
asyncio.to_thread(load_latest_ai_agent_log_post_write_verifier_dry_run),
load_latest_ai_agent_log_controlled_writeback_consumer_readback(),
load_latest_telegram_alert_learning_context_post_apply_verifier(),
)
apply_gitea_repo_bundle_backup_readback(reboot_slo, gitea_bundle_readback)
apply_stockplatform_runtime_readback(reboot_slo, stockplatform_runtime)
@@ -1250,33 +1262,15 @@ async def _build_awoooi_priority_work_order_readback_with_live_overlays() -> dic
payload,
stockplatform_recovery,
)
harbor_recovery = await asyncio.to_thread(
load_latest_harbor_registry_controlled_recovery_preflight
)
apply_harbor_registry_controlled_recovery_preflight(
payload,
harbor_recovery,
)
log_executor = await asyncio.to_thread(
load_latest_ai_agent_log_controlled_writeback_executor_readback
)
apply_ai_loop_current_blocker_execution_queue(payload, log_executor)
controlled_cd_lane_metrics = await asyncio.to_thread(
load_controlled_cd_lane_live_metric_readback
)
apply_controlled_cd_lane_live_metric_readback(
payload,
controlled_cd_lane_metrics,
)
post_write_verifier = await asyncio.to_thread(
load_latest_ai_agent_log_post_write_verifier_dry_run
)
consumer_readback = (
await load_latest_ai_agent_log_controlled_writeback_consumer_readback()
)
telegram_alert_context_verifier = (
await load_latest_telegram_alert_learning_context_post_apply_verifier()
)
apply_ai_automation_live_closure_readbacks(
payload,
executor_readback=log_executor,