Skip to content

Document storage.blobRetention - #622

Draft
kriszyp wants to merge 1 commit into
mainfrom
kris/blob-retention-docs
Draft

Document storage.blobRetention#622
kriszyp wants to merge 1 commit into
mainfrom
kris/blob-retention-docs

Conversation

@kriszyp

@kriszyp kriszyp commented Aug 11, 2026

Copy link
Copy Markdown
Member

Documents storage.blobRetention, the new config option added in HarperFast/harper#2145.

The option controls how long a superseded blob file stays on disk. The section explains why the window exists (blob bytes are read lazily, so a request that resolved a record just before it was overwritten opens the file afterwards — and the resulting failure lands after the response headers are committed, so the client sees a truncated body rather than an error), when to raise it (large blobs, slow clients, a cache table rewritten while being served, replication lag), and what it costs (write rate × window of superseded bytes on disk, plus a wider window for files orphaned by an abrupt exit).

Placed in reference/database/storage-tuning.md next to storage.blobPaths, matching the surrounding option format.

Verification

Prose-only change to an existing reference page; no build run — npx prettier cannot run in this worktree (@harperfast/code-guidelines is not installed), so formatting was matched to the surrounding sections by hand. Worth a docs-site preview check before merge.

For the human reviewer

One judgment call: I documented the replication-lag guidance ("a cluster with significant replication lag wants a value comfortably above that lag") as a real tuning lever. That is accurate for the current design but is exactly the workaround that lag-aware retention would remove — if harper#2145's judgment call 1 goes the other way, this paragraph should be revisited rather than kept.

🤖 Generated by Claude (claude-opus-5)

New in harper#2145: how long a superseded blob file is kept on disk so an
in-flight read (or a replication peer that has not fetched it yet) can still
get the bytes, and the disk cost of widening it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds documentation for the storage.blobRetention configuration option in reference/database/storage-tuning.md. The feedback suggests adding a version badge under the heading to indicate when this configuration option was introduced, aligning with the repository's documentation guidelines.

Blobs are not relocated when `blobPaths` changes — only new blobs honor the updated configuration. Existing blob references continue to resolve at their original path.

### `storage.blobRetention`

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

According to the repository's guidelines, we should include a version badge when documenting new configuration options or behavior changes to indicate when they were introduced. Please add the appropriate <VersionBadge type="changed" version="v5.2.0" /> under the heading.

Suggested change
<VersionBadge type="changed" version="v5.2.0" />
References
  1. Use the <VersionBadge type="changed" version="vX.Y.0" /> format when documenting behavior changes to existing surface, as prescribed in the repository's guidelines.

@github-actions

Copy link
Copy Markdown

🚀 Preview Deployment

Your preview deployment is ready!

🔗 Preview URL: https://preview.harper-documentation.harperfabric.com/pr-622

This preview will update automatically when you push new commits.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant