Skip to content

Add TsFile v4 file format documentation - #1039

Merged
ColinLeeo merged 14 commits into
docs/devfrom
doc/tsfile-file-format-v2
Oct 28, 2026
Merged

ColinLeeo merged 14 commits into
docs/devfrom
doc/tsfile-file-format-v2

Conversation

@ColinLeeo

@ColinLeeo ColinLeeo commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Add TsFile v4 binary file format documentation in English and Chinese under UserGuide/latest/FileFormat.
  • Cover the physical layout, metadata/index structures, Chunks/Pages, Statistics, encodings, compression, nulls, Bloom filter, legacy and Page AEAD encryption, and error recovery.
  • Add an interactive TsFileStructureTree component plus sidebar entries in both locales. The tree descends through Page Header/Page Data, Timeseries Statistics/Chunk Metadata, and the table/device index roots, showing offset, size, and one row per field with its own note.
  • Mutually exclusive layouts are shown as an explicit choice with an or divider between the options, so they are not mistaken for a sequence; fields inside one structure stay as ordered rows.
  • The encoding chapter documents codec identifiers and the PLAIN layout; the bit layouts of other value codecs are out of scope.

Test plan

  • pnpm docs:build — 162 pages, no dead links.
  • Checked every structure-tree link target against the generated pages.
  • Verified the format details against the implementations in java/ (Statistics, index nodes, encodings, compression IDs, Bloom hashing, Page AEAD layout).

@ColinLeeo ColinLeeo added bot:triaged managed by TsFile maintainer bot bot:need-review managed by TsFile maintainer bot and removed bot:triaged managed by TsFile maintainer bot bot:need-review managed by TsFile maintainer bot labels Oct 27, 2026
@ColinLeeo
ColinLeeo marked this pull request as draft October 28, 2026 03:17
@ColinLeeo

Copy link
Copy Markdown
Contributor Author

Warning

New commits since the last review

The previous review verdict has been withdrawn and this PR has been marked as Draft.

Next steps: fix the remaining items, run the full test suite locally, then click Ready for review (or comment /ready). CI and review will run again automatically.

@ColinLeeo ColinLeeo added bot:needs-check managed by TsFile maintainer bot and removed bot:need-review managed by TsFile maintainer bot labels Oct 28, 2026
Break the metadata index root into its table-name prefix and device index
root, and explain the lookup path down to Chunk Metadata.
The parsed layout rows already carry the grammar, so the raw notation is
redundant.
Stacked rows read like a sequence. Mark alternative children and separate
them with an 'or' divider, and make Chunk Layout spell out its two forms.
@ColinLeeo
ColinLeeo force-pushed the doc/tsfile-file-format-v2 branch from 9b90e2e to 5c83c69 Compare October 28, 2026 03:56
No section documents the file header on its own, so the link promised
content that does not exist. The children still point at the version page.
@ColinLeeo
ColinLeeo marked this pull request as ready for review October 28, 2026 04:04
@ColinLeeo ColinLeeo added bot:need-ci managed by TsFile maintainer bot and removed bot:needs-check managed by TsFile maintainer bot labels Oct 28, 2026
@ColinLeeo
ColinLeeo merged commit 34c2fdc into docs/dev Oct 28, 2026
2 checks passed
@ColinLeeo
ColinLeeo deleted the doc/tsfile-file-format-v2 branch October 28, 2026 04:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot:need-ci managed by TsFile maintainer bot

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant