openclaw - 💡(How to fix) Fix Gateway restart slow in 4.25 — hardcoded startup-grace and channel-connect-grace [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#72911Fetched 2026-04-28 06:30:23
View on GitHub
Comments
1
Participants
2
Timeline
3
Reactions
0
Author
Participants
Timeline (top)
closed ×1commented ×1cross-referenced ×1

Root Cause

Health monitor in 4.25 introduces hardcoded grace periods:

[health-monitor] started (interval: 300s, startup-grace: 60s, channel-connect-grace: 120s)

These values are not exposed in config schema and cannot be adjusted by users.

Code Example

00:10:24 [gateway] ready (4 plugins; 4.6s)
00:10:24 [gateway] starting channels and sidecars...
00:10:50 [openclaw-weixin] starting weixin provider   ← 27s gap
00:10:51 [browser/server] Browser control listening
00:10:51 [feishu] starting feishu[default]

---

[health-monitor] started (interval: 300s, startup-grace: 60s, channel-connect-grace: 120s)

---

Feishu: failed (unknown) - probe timed out after 10000ms
RAW_BUFFERClick to expand / collapse

Problem

After upgrading to OpenClaw 2026.4.25, gateway restarts take significantly longer due to a ~27 second delay between "gateway ready" and channel initialization.

Timeline from logs

00:10:24 [gateway] ready (4 plugins; 4.6s)
00:10:24 [gateway] starting channels and sidecars...
00:10:50 [openclaw-weixin] starting weixin provider   ← 27s gap
00:10:51 [browser/server] Browser control listening
00:10:51 [feishu] starting feishu[default]

The actual gateway core boots in 4.6 seconds, but channels don't start for another 27 seconds.

Root cause

Health monitor in 4.25 introduces hardcoded grace periods:

[health-monitor] started (interval: 300s, startup-grace: 60s, channel-connect-grace: 120s)

These values are not exposed in config schema and cannot be adjusted by users.

Environment

  • OpenClaw: 2026.4.25 (aa36ee6)
  • OS: macOS 26.4.1 (arm64) · Node 22.22.0
  • Channels: Feishu, openclaw-weixin (3 accounts), browser
  • Session store: 38MB / 200 files (already cleaned)
  • Previous version: 2026.4.21 — restarts were fast, no delay observed

Impact

  • Gateway restarts and config reloads feel sluggish
  • Hot-reload config changes (e.g. bootstrap limits) still trigger a full ~30s restart cycle
  • Channel probe timeout in openclaw doctor:
    Feishu: failed (unknown) - probe timed out after 10000ms

Suggested fix

  1. Make startup-grace and channel-connect-grace configurable via gateway.healthMonitor.startupGraceSeconds / channelConnectGraceSeconds
  2. Reduce defaults for local/dev mode (e.g. 5–10s instead of 60–120s)
  3. Skip startup-grace entirely when gateway detects a local loopback-only bind (127.0.0.1)

Related

  • #72804 — browser proxy configuration feature request (also a hardcoded-behavior issue)

extent analysis

TL;DR

The 27-second delay in gateway restarts can be mitigated by making the startup-grace and channel-connect-grace periods configurable and reducing their default values.

Guidance

  • Review the suggested fix to make startup-grace and channel-connect-grace configurable via gateway.healthMonitor.startupGraceSeconds and channelConnectGraceSeconds.
  • Consider reducing the default values for local/dev mode to 5-10 seconds to minimize the delay.
  • Evaluate the possibility of skipping the startup-grace period when the gateway detects a local loopback-only bind (127.0.0.1).
  • Verify the fix by checking the gateway restart time and channel initialization after applying the configuration changes.

Example

No code snippet is provided as the issue does not require a specific code change, but rather a configuration adjustment.

Notes

The suggested fix requires changes to the OpenClaw configuration schema to expose the startup-grace and channel-connect-grace periods. The exact implementation details are not provided in the issue.

Recommendation

Apply the workaround by configuring the startup-grace and channel-connect-grace periods to reduced values (e.g., 5-10 seconds) to minimize the delay, as the issue is caused by hardcoded grace periods in the health monitor.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix Gateway restart slow in 4.25 — hardcoded startup-grace and channel-connect-grace [1 comments, 2 participants]