Repository navigation
docs(deploy): document JetStream SyncAlways durability vs throughput - #338
Conversation
WaveHouse runs embedded NATS JetStream with SyncAlways=true (internal/mq/embedded.go), so every event is fsync'd to disk before POST /v1/ingest returns 200 — making the storage substrate's fsync tail the ingest latency floor. That contract was implicit and undocumented. Add an Operations guide (docs/src/content/docs/durability.md) covering: - what a 200 ack guarantees vs JetStream's default page-cache mode - why a slow fsync tail surfaces as `create stream: context deadline exceeded` and 503 backpressure - where SyncAlways is cheap vs expensive (cloud block storage / PLP NVMe vs ZFS-without-SLOG / qcow2-on-ext4 / spinning disks) - an fio recipe + verdict bands to measure your own storage, with the macOS F_FULLFSYNC honesty caveat - symptom checklist Forward-references the configurable group-commit interval (mq.sync_interval, #139) and the planned `wavehouse storage-check` preflight (#84) without claiming either exists yet. Register the page in the sidebar and cross-link from Configuration, Deployment, and the Ingest Pipeline's worker-side ack section. Documents #84. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📜 Recent review details⏰ Context from checks skipped due to timeout of 300000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
🧰 Additional context used📓 Path-based instructions (1)docs/src/content/docs/**/*.{md,mdx}📄 CodeRabbit inference engine (AGENTS.md)
Files:
🧠 Learnings (1)📚 Learning: 2026-06-10T15:01:09.027ZApplied to files:
🪛 LanguageTooldocs/src/content/docs/configuration.mdx[typographical] ~128-~128: The word ‘When’ starts a question. Add a question mark (“?”) at the end of the sentence. (WRB_QUESTION_MARK) 🔇 Additional comments (6)
📝 WalkthroughSummary by CodeRabbit
WalkthroughThis PR adds comprehensive documentation of WaveHouse durability guarantees under embedded JetStream with ChangesDurability & Storage Operations Documentation
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related issues
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: e9b01932-286f-4f62-8e6e-215c3604c34d
📒 Files selected for processing (6)
CHANGELOG.mddocs/src/config/sidebar.tsdocs/src/content/docs/configuration.mdxdocs/src/content/docs/deployment.mddocs/src/content/docs/durability.mddocs/src/content/docs/reverse-proxy.mdx
📜 Review details
⏰ Context from checks skipped due to timeout of 300000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
- GitHub Check: Docs build
- GitHub Check: Lint
- GitHub Check: Analyze (go)
- GitHub Check: Analyze (javascript-typescript)
- GitHub Check: Analyze (go)
🧰 Additional context used
📓 Path-based instructions (6)
**/*.md
📄 CodeRabbit inference engine (AGENTS.md)
Markdown files must pass markdownlint style checks (enforce via
make lint)
Files:
docs/src/content/docs/durability.mddocs/src/content/docs/deployment.mdCHANGELOG.md
**/*.{md,mdx}
📄 CodeRabbit inference engine (AGENTS.md)
Markdown documentation files must pass docs-prose review (accuracy vs. code, examples, clarity, completeness); scope is canonical set from
scripts/docs-prose.shexcluding.claude/**,.github/**,CHANGELOG.md,AGENTS.md,CLAUDE.md,*.draft.md,*.old.md
Files:
docs/src/content/docs/durability.mddocs/src/content/docs/deployment.mdCHANGELOG.mddocs/src/content/docs/reverse-proxy.mdxdocs/src/content/docs/configuration.mdx
docs/src/content/**/*.{md,mdx}
📄 CodeRabbit inference engine (AGENTS.md)
When authoring Mermaid diagrams in Markdown: author vertically (top-down default,
flowchart TB/TD) to fit page column (~46–58rem); keep node labels short with<br/>for multi-line; use semantic node classes (wh,win,pain,fail,infra,neutral,store,client); never sit two large diagrams side-by-side without<div class="diagram-pair">wrapper
Files:
docs/src/content/docs/durability.mddocs/src/content/docs/deployment.mddocs/src/content/docs/reverse-proxy.mdxdocs/src/content/docs/configuration.mdx
**/*.{ts,tsx,js,jsx,json}
📄 CodeRabbit inference engine (AGENTS.md)
TypeScript/JavaScript code must use strict formatting enforced by Biome (markdownlint for Markdown style, misspell for spelling)
Files:
docs/src/config/sidebar.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (AGENTS.md)
TypeScript code must pass type checking via
tsc(TypeScript compiler)
Files:
docs/src/config/sidebar.ts
**/*.{ts,tsx,js,jsx}
📄 CodeRabbit inference engine (AGENTS.md)
TypeScript/JavaScript import statements must follow ESM (ECMAScript modules) conventions; use
importnotrequireunless Node.js tooling requires it
Files:
docs/src/config/sidebar.ts
🧠 Learnings (1)
📚 Learning: 2026-06-10T15:01:09.027Z
Learnt from: EricAndrechek
Repo: Wave-RF/WaveHouse PR: 312
File: docs/src/content/docs/development.md:0-0
Timestamp: 2026-06-10T15:01:09.027Z
Learning: In this repo’s Markdown review (all .md files), do not flag capitalization/style issues for literal paths starting with ".github/" (or any substring that is a path beginning with ".github/"). Treat ".github" as the correct lowercase dotfile directory name, even when it appears inside prose or code spans; automated checks such as LanguageTool’s "(GITHUB)" rule commonly produce false positives for this literal filesystem path.
Applied to files:
docs/src/content/docs/durability.mddocs/src/content/docs/deployment.mdCHANGELOG.md
🪛 LanguageTool
docs/src/content/docs/durability.md
[style] ~34-~34: Consider using the typographical ellipsis character here instead.
Context: ...hem exceed it. The boot-time symptom is create stream: ... context deadline exceeded. - If the wo...
(ELLIPSIS)
🔇 Additional comments (12)
docs/src/content/docs/durability.md (8)
1-6: LGTM!
8-10: LGTM!
12-27: LGTM!
29-35: LGTM!
37-57: LGTM!
59-88: LGTM!
90-97: LGTM!
99-103: LGTM!docs/src/config/sidebar.ts (1)
49-49: LGTM!docs/src/content/docs/configuration.mdx (1)
67-67: LGTM!docs/src/content/docs/deployment.md (1)
174-174: LGTM!docs/src/content/docs/reverse-proxy.mdx (1)
5-5: LGTM!
|
📚 Docs preview is live → https://b3c4ad11-wavehouse-docs.wave-rf.workers.dev
|
What
Adds a Durability & Storage operations page (
docs/src/content/docs/durability.md) that makes the embedded-JetStream durability contract explicit, and wires it into the nav + cross-links.The core fact this documents: WaveHouse starts embedded NATS with
SyncAlways: true(internal/mq/embedded.go), so every event isfsync'd to disk beforePOST /v1/ingestreturns200. That makes the storage substrate'sfsynctail the ingest latency floor — a deliberate, strong guarantee that was previously implicit and undocumented.Why
Per #84, the durability/throughput tradeoff is a product decision worth documenting independently of the infra mitigation in support-infra#1. The issue author flagged this as the docs-site-publish-gating "item" (comment): operators need to know what a
200ack guarantees and how to tell whether their storage can sustain it before they go live.The new page covers
200=fsync'd to local disk, and how that differs from JetStream's default (ack from OS page cache, periodic background flush).fsynctail is the ingest floor — and why a slow substrate surfaces ascreate stream: ... context deadline exceededat boot and503backpressure under load.SyncAlwaysis cheap vs. expensive — managed cloud block storage / PLP NVMe / local ext4 vs. ZFS-without-SLOG / qcow2-on-ext4 / spinning disks.fiorecipe + verdict bands (calibrated to theSyncAlwaysdefault), with the macOSF_FULLFSYNChonesty caveat.Cross-links / wiring
docs/src/config/sidebar.tsunder Operations (between Deployment and Behind a reverse proxy; reverse-proxy'ssidebar.orderbumped 11→12).CHANGELOG.md[Unreleased] → Added.Scope (and what's intentionally out of it)
This PR is the documentation deliverable of #84. It does not:
mq.sync_intervalconfig knob — that's the code-side companion, tracked in #139. The page forward-references it without claiming it exists yet.wavehouse storage-checkCLI subcommand — a larger feature still tracked in docs(deploy): JetStream SyncAlways=true durability vs throughput on commodity storage #84. The page forward-references it as planned.I used "Documents #84" rather than "Closes #84" so the issue stays open to track those two remaining deliverables. Suggest splitting the
storage-checkCLI into its own issue and closing #84 once the docs land, or keeping it open until the CLI ships — reviewer's call.Testing
make build-docs✅ — 21 pages built,starlight-links-validatorclean (all new cross-link anchors resolve),astro checkpasses.make verify✅ (pre-commit) — markdownlint, misspell, astro content-schema check.scripts/classify-paths.sh→code=false), so no Go/SDK suites apply.🤖 Generated with Claude Code