Prodrome Digest 0.10.1 packages Rust software for two-threshold log summaries
The Rust library builds a summary tree over an append-only log and uses two byte thresholds to shape a view.
A reading view over an event log
Prodrome Digest 0.10.1 appeared on crates.io on November 28 at 23:14:52 UTC, which was November 29 at 02:14:52 in Istanbul. Docs.rs has a separate build record. The release archive contains Rust modules for turning an append-only log into a summary tree and constructing a view over it. The view can represent periods with raw lines or summaries that already exist. That arrangement can help an application display recent task changes together with condensed history.
An upper threshold triggers a merge
The Waters type holds high and low thresholds in bytes. If a new part takes the view above the high threshold, the merge mechanism can close eligible ranges until cost reaches the low threshold or further closing is unavailable. An application might choose 1,200 bytes as the trigger and 900 as the target for a fixture. Those numbers are illustrative. Outcomes depend on the costs attached to lines and the summaries already available.
The calling application owns summary text
The crate reads a summary's availability and byte length from the calling application. The caller also supplies the cost of displaying an original line. For example, an application might measure the UTF-8 bytes of the text it actually stores. Keep the range represented by each chosen part available for inspection. The original records may still be useful when a displayed summary prompts a closer review.
An unavailable summary is a fixture case
A test can leave a summary missing for some nodes and record the raw lines that the view uses. Then add a summary for the same range and rerun the fixture. Compare the represented ranges and accounted byte costs. Cover the case where the high threshold is exceeded and there are no further eligible summaries. This lets the application team decide how it will handle that presentation case.
Compare costs while preserving the original range
To compare release behavior, run a fixed log and then increase the byte cost of a few lines. Record where merging begins and which ranges the view selects. Include a check that the underlying log remains readable. Package inspection confirmed the distributed tree, view, pending-summary and threshold definitions. The cover is an archival photograph of a ledger from the Metropolitan Museum of Art, illustrating the idea of a recorded history.
Keep the number of records and the view cost distinct
A view with a few summarized parts can still represent many original events. Retain both quantities when reading results from a fixture. Keep the number of original lines, the number of pieces selected for the view and the configured measure as separate observations. Use the same set of source lines and existing summaries when running a comparison again.
Photo · The Metropolitan Museum of Art / Wikimedia Commons / The Met Open Access. Resized and converted to WebP. ↗ · CC0 1.0
Sources and verification
- Primary sourcecrates.io ↗
- Technical documentDocs.rs ↗
- Reporting / cross-checkDocs.rs — build ↗
Reader discussion
What would you change first for maintainability and testing in your own project?
No comments yet. Be the first to contribute.
Write a comment