惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

J
Java Code Geeks
F
Fortinet All Blogs
云风的 BLOG
云风的 BLOG
MyScale Blog
MyScale Blog
D
DataBreaches.Net
Stack Overflow Blog
Stack Overflow Blog
A
About on SuperTechFans
Google DeepMind News
Google DeepMind News
Microsoft Security Blog
Microsoft Security Blog
腾讯CDC
The GitHub Blog
The GitHub Blog
Jina AI
Jina AI
B
Blog RSS Feed
I
InfoQ
N
Netflix TechBlog - Medium
T
The Blog of Author Tim Ferriss
Microsoft Azure Blog
Microsoft Azure Blog
Recent Announcements
Recent Announcements
GbyAI
GbyAI
H
Help Net Security
L
LangChain Blog
M
MIT News - Artificial intelligence
Y
Y Combinator Blog
aimingoo的专栏
aimingoo的专栏

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
perf(gateway): defer scheduled service imports · openclaw...
steipete · 2026-05-27 · via Recent Commits to openclaw:main

@@ -1114,14 +1114,13 @@ export async function startGatewayServer(

11141114

getActiveTaskCount = earlyRuntime.getActiveTaskCount;

11151115

runtimeState.skillsChangeUnsub = earlyRuntime.skillsChangeUnsub;

111611161117-

const [{ startGatewayEventSubscriptions }, gatewayRuntimeServices] = await startupTrace.measure(

1118-

"runtime.post-early-imports",

1119-

() =>

1117+

const [{ startGatewayEventSubscriptions }, { startGatewayRuntimeServices }] =

1118+

await startupTrace.measure("runtime.post-early-imports", () =>

11201119

Promise.all([

11211120

import("./server-runtime-subscriptions.js"),

1122-

import("./server-runtime-services.js"),

1121+

import("./server-runtime-startup-services.js"),

11231122

]),

1124-

);

1123+

);

11251124

const runtimeSubscriptions = await startupTrace.measure("runtime.subscriptions", () =>

11261125

startGatewayEventSubscriptions({

11271126

broadcast,

@@ -1138,7 +1137,7 @@ export async function startGatewayServer(

11381137

Object.assign(runtimeState, runtimeSubscriptions);

1139113811401139

const runtimeServices = await startupTrace.measure("runtime.services", () =>

1141-

gatewayRuntimeServices.startGatewayRuntimeServices({

1140+

startGatewayRuntimeServices({

11421141

minimalTestGateway,

11431142

cfgAtStart,

11441143

channelManager,

@@ -1516,6 +1515,13 @@ export async function startGatewayServer(

15161515

const sessionDeliveryRecoveryMaxEnqueuedAt = Date.now();

15171516

let postAttachRuntimeReturned = false;

15181517

let scheduledServicesActivated = false;

1518+

let scheduledServicesModulePromise: Promise<

1519+

typeof import("./server-runtime-services.js")

1520+

> | null = null;

1521+

const loadScheduledServicesModule = () => {

1522+

scheduledServicesModulePromise ??= import("./server-runtime-services.js");

1523+

return scheduledServicesModulePromise;

1524+

};

15191525

const activateScheduledServicesWhenReady = () => {

15201526

if (

15211527

closePreludeStarted ||

@@ -1525,20 +1531,25 @@ export async function startGatewayServer(

15251531

) {

15261532

return;

15271533

}

1528-

const activated = gatewayRuntimeServices.activateGatewayScheduledServices({

1529-

minimalTestGateway,

1530-

cfgAtStart,

1531-

deps,

1532-

sessionDeliveryRecoveryMaxEnqueuedAt,

1533-

cron: runtimeState.cronState.cron,

1534-

startCron: false,

1535-

logCron,

1536-

log,

1537-

pluginLookUpTable,

1538-

});

15391534

scheduledServicesActivated = true;

1540-

runtimeState.heartbeatRunner = activated.heartbeatRunner;

1541-

runtimeState.stopModelPricingRefresh = activated.stopModelPricingRefresh;

1535+

void loadScheduledServicesModule().then((gatewayRuntimeServices) => {

1536+

if (closePreludeStarted) {

1537+

return;

1538+

}

1539+

const activated = gatewayRuntimeServices.activateGatewayScheduledServices({

1540+

minimalTestGateway,

1541+

cfgAtStart,

1542+

deps,

1543+

sessionDeliveryRecoveryMaxEnqueuedAt,

1544+

cron: runtimeState.cronState.cron,

1545+

startCron: false,

1546+

logCron,

1547+

log,

1548+

pluginLookUpTable,

1549+

});

1550+

runtimeState.heartbeatRunner = activated.heartbeatRunner;

1551+

runtimeState.stopModelPricingRefresh = activated.stopModelPricingRefresh;

1552+

});

15421553

};

15431554

({

15441555

stopGatewayUpdateCheck: runtimeState.stopGatewayUpdateCheck,

@@ -1693,6 +1704,7 @@ export async function startGatewayServer(

16931704

log.warn(`gateway: failed to promote config last-known-good backup: ${String(err)}`);

16941705

});

16951706

if (!minimalTestGateway) {

1707+

const gatewayRuntimeServices = await loadScheduledServicesModule();

16961708

postReadyMaintenanceTimer = gatewayRuntimeServices.scheduleGatewayPostReadyMaintenance({

16971709

delayMs: POST_READY_MAINTENANCE_DELAY_MS,

16981710

isClosing: () => closePreludeStarted,