Expand description
Wall-clock parsing for AS OF SYSTEM TIME '<datetime>'.
Zero-dependency by the same rule the daemon keeps: ISO-8601 subsets and unix timestamps are grammar, not an ecosystem. What is accepted:
| form | example | meaning |
|---|---|---|
| RFC 3339 / ISO datetime | 2026-09-15T17:00:00Z, 2026-09-15 17:00:00 | wall-clock moment |
| date only | 2026-09-15 | midnight UTC of that day |
| epoch with unit | 1757955600s, 1757955600000ms | wall-clock moment (explicit — see below) |
A bare integer stays a sequence number and never reaches this module:
that is the entire backcompat contract. Every query that worked before this
existed means the same thing it always did. A unix value must carry an
explicit s/ms suffix — silently reinterpreting 1757955600 as “September
2026” would answer a question about the past with whatever happens to be at
seq 1.7 billion, which is the same failure shape as dropping an AS OF
silently: a confident answer to a question nobody asked.
Fractional seconds are accepted in the datetime form. Offsets other than
Z (+02:00) are accepted and normalised; a naive datetime (no offset)
is read as UTC, stated here rather than guessed per deployment.
The resolution rule — “the last write at or before T” — lives with the
engine’s ts index (Db::seq_at), not here. This module only turns text
into a moment.
Structs§
- Wall
Clock - A parsed wall-clock moment, as epoch seconds (fractional).
Enums§
Constants§
- WALL_
CLOCK_ FLAG - High bit tagging a marker as a wall-clock moment rather than a sequence.