openclaw - ✅(Solved) Fix Active Memory docs recommend cacheTtlMs: 300000 but schema rejects > 120000 [1 pull requests, 1 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#65708Fetched 2026-04-14 05:40:41
View on GitHub
Comments
0
Participants
1
Timeline
2
Reactions
0
Participants
Timeline (top)
cross-referenced ×1referenced ×1

Active Memory config docs recommend cacheTtlMs values up to 300000 ms (5 min), but the zod schema rejects anything greater than 120000 ms (2 min). Following the docs literally causes the gateway to crash-loop on startup.

Error Message

We hit this yesterday during an Active Memory rollout. Container crash-looped 7+ times before we grepped docker logs for the actual schema error. Fix was a one-character edit to .openclaw.json, but the mismatch between docs and schema was the hard part.

Root Cause

Active Memory config docs recommend cacheTtlMs values up to 300000 ms (5 min), but the zod schema rejects anything greater than 120000 ms (2 min). Following the docs literally causes the gateway to crash-loop on startup.

Fix Action

Fixed

PR fix notes

PR #65737: docs(active-memory): document cacheTtlMs bounds (#65708)

Description (problem / solution / changelog)

Summary

The Active Memory tuning-fields table listed `cacheTtlMs` without its bounds. The zod schema and the plugin manifest cap it at 1000–120000 ms with a 15000 ms default. A user following older "paste this in" snippets with `cacheTtlMs: 300000` crash-looped the gateway on startup with an opaque schema error before figuring out the real limit (#65708).

Document the range and default inline in the table so the limit is discoverable before boot.

Test plan

  • `docs/concepts/active-memory.md` renders correctly in Mintlify markdown preview
  • Bounds match `extensions/active-memory/index.ts:651` (`clampInt(raw.cacheTtlMs, DEFAULT_CACHE_TTL_MS, 1000, 120_000)`) and `extensions/active-memory/openclaw.plugin.json:57` (`minimum: 1000, maximum: 120000`)
  • Default matches `DEFAULT_CACHE_TTL_MS = 15_000` at `extensions/active-memory/index.ts:26`

Closes #65708

🤖 Generated with Claude Code

Changed files

  • docs/concepts/active-memory.md (modified, +8/-8)

Code Example

Config invalid
File: ~/.openclaw/openclaw.json
Problem:
  - plugins.entries.active-memory.config.cacheTtlMs: invalid config: must be <= 120000
RAW_BUFFERClick to expand / collapse

Summary

Active Memory config docs recommend cacheTtlMs values up to 300000 ms (5 min), but the zod schema rejects anything greater than 120000 ms (2 min). Following the docs literally causes the gateway to crash-loop on startup.

Reproduce

In a v2026.4.11 gateway config, add Active Memory per docs example. Docs at /app/docs/concepts/active-memory.md say:

config.cacheTtlMs — Cache reuse for repeated identical queries

No maximum documented. The paste-this-in recommended snippet in the same doc explicitly uses cacheTtlMs: 300000.

Attempt to start gateway with plugins.entries.active-memory.config.cacheTtlMs = 300000:

Config invalid
File: ~/.openclaw/openclaw.json
Problem:
  - plugins.entries.active-memory.config.cacheTtlMs: invalid config: must be <= 120000

Gateway enters crash-loop. Only lowering to <=120000 resolves it.

Expected

Either:

  • Docs updated to document the actual maximum (120000 ms / 2 min), OR
  • Schema relaxed to allow up to 300000 ms (matching recommended snippet)

Impact

We hit this yesterday during an Active Memory rollout. Container crash-looped 7+ times before we grepped docker logs for the actual schema error. Fix was a one-character edit to .openclaw.json, but the mismatch between docs and schema was the hard part.

Environment

  • OpenClaw v2026.4.11
  • plugins.entries.active-memory first-time setup
  • zod schema validation at gateway boot

Proposed minimal fix

Docs update preferred (schema is sane — 2 min cache is fine for pre-reply memory recall). Just remove the 300000 from the "Paste This Into Your Agent" snippet in concepts/active-memory.md and add a sentence: "cacheTtlMs — max 120000 ms (2 min). Repeated identical queries within this window reuse the prior result."

extent analysis

TL;DR

Update the cacheTtlMs value in the gateway config to 120000 ms or less to prevent the crash-loop.

Guidance

  • Verify that the cacheTtlMs value in the plugins.entries.active-memory.config section of the gateway config is set to 120000 ms or less.
  • Check the Active Memory config docs at /app/docs/concepts/active-memory.md for the recommended cacheTtlMs value and ensure it matches the schema validation.
  • If using the "Paste This Into Your Agent" snippet, remove the 300000 value and use the updated recommended value of 120000 ms.
  • Consider updating the docs to reflect the actual maximum cacheTtlMs value of 120000 ms to prevent similar issues in the future.

Example

No code snippet is necessary in this case, as the issue is related to configuration values.

Notes

The issue is specific to OpenClaw v2026.4.11 and the plugins.entries.active-memory setup. The proposed minimal fix is to update the docs to reflect the actual maximum cacheTtlMs value.

Recommendation

Apply workaround: update the cacheTtlMs value to 120000 ms or less to prevent the crash-loop, as the schema validation is sane and 2 min cache is fine for pre-reply memory recall.

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