docs(plugins): document safe external cron projection#104227
Merged
Conversation
Contributor
Author
|
Land-ready verification completed at exact head
Known proof boundary: this is a vendor-neutral documentation contract, not a concrete host integration. The example explicitly requires the host adapter to provide atomic/idempotent full replacement, durable acceptance, and abort-before-accept semantics; OpenClaw does not claim to provide an outbox for those external effects. |
Contributor
Author
|
Merged via squash.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Jul 12, 2026
* docs(plugins): document safe cron projection * docs(plugins): serialize cron projection revisions * docs: refresh generated map * docs(plugins): cancel stale cron projections
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #104083
What Problem This Solves
Fixes an issue where plugin authors could mistake a hook
timeoutMsfor cancellation and allow external scheduler writes to outlive the lifecycle they thought they were bounded by. The cron lifecycle docs also lacked a complete safe pattern for projecting wakes to a hosting platform.Why This Change Was Made
The docs now state the actual await-only timeout contract and provide one vendor-neutral, full-snapshot cron projection pattern. The example keeps scheduler ownership at
cron_reconciled, treatscron_changedas a coalescible hint, serializes replacement, waits for durable host acceptance, retries with bounded backoff, and aborts/drains/closes ongateway_stopwithout adding a core outbox.User Impact
Plugin and hosting-integration authors can implement wake scheduling without relying on lossy event ordering, adopting a stale scheduler after reload, or assuming OpenClaw cancels timed-out plugin work. The SDK and external-app guides now route readers to the same canonical contract.
Evidence
pnpm docs:listpnpm format:docs:check— clean across 689 filespnpm docs:check-mdx— 705 files passedpnpm docs:check-links— 5,812 internal links checked, 0 brokenpnpm docs:check-i18n-glossary— passed against the fetchedmainmerge basepnpm docs:map:check— generated map current; adds the new section and refreshes one existing current-main headingtsgoagainst the repository config.agents/skills/autoreview/scripts/autoreview --mode branch --base origin/main --engine codex --model gpt-5.5 --thinking high— clean, no accepted/actionable findings