Conversation
73b3ef5 to
e8db6a1
Compare
Contributor
Greptile SummaryThis PR enables append pipelining by default in s2-lite, completing the work tracked in issue #48. It decouples DB write submission (now using Key points from the review:
Confidence Score: 4/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant Client
participant StreamerClient
participant Streamer
participant DB as SlateDB
participant DurabilityNotifier
Client->>StreamerClient: append_permit(input)
StreamerClient->>StreamerClient: acquire_many(metered_size) on shared semaphore
StreamerClient-->>Client: AppendPermit
Client->>StreamerClient: permit.submit()
StreamerClient->>Streamer: Message::Append (via msg_tx)
Streamer->>Streamer: handle_append → sequence_records
Streamer->>Streamer: push db_submit_append future → db_writes_pending
Streamer->>DB: write_with_options(wb, await_durable=false)
DB-->>Streamer: WriteHandle { seqnum: db_seq }
Streamer->>Streamer: push InFlightAppend { db_seq, records } → inflight_appends
Streamer->>DurabilityNotifier: subscribe(db_seq, callback)
Note over Streamer: Multiple in-flight appends allowed here
DB->>DurabilityNotifier: db.subscribe() watch fires (durable_seq advances)
DurabilityNotifier->>DurabilityNotifier: notify_waiters → fire callbacks
DurabilityNotifier->>Streamer: Message::DurabilityStatus(Ok(durable_seq)) (via msg_tx)
Streamer->>Streamer: on_db_durable_seq_advanced(durable_seq)
Streamer->>Streamer: pop inflight_appends → stable_pos, follow_tx.send, pending_appends.on_stable
Streamer-->>Client: AppendAck (via oneshot reply_tx)
StreamerClient->>StreamerClient: drop(sema_permit) — releases semaphore
Last reviewed commit: 7a8e490 |
Merged
shikhar
pushed a commit
that referenced
this pull request
Mar 6, 2026
## 🤖 New release * `s2-lite`: 0.29.19 -> 0.29.20 (✓ API compatible changes) * `s2-sdk`: 0.24.6 -> 0.24.7 (✓ API compatible changes) * `s2-cli`: 0.29.19 -> 0.29.20 <details><summary><i><b>Changelog</b></i></summary><p> ## `s2-lite` <blockquote> ## [0.29.20] - 2026-03-06 ### Features - Default append pipelining with durability-gated acks ([#289](#289)) ### Bug Fixes - Keep follow sessions alive across dormancy ([#301](#301)) ### Miscellaneous Tasks - Dep updates ([#299](#299)) <!-- generated by git-cliff --> </blockquote> ## `s2-sdk` <blockquote> ## [0.24.7] - 2026-03-06 ### Miscellaneous Tasks - Dep updates ([#299](#299)) <!-- generated by git-cliff --> </blockquote> ## `s2-cli` <blockquote> ## [0.29.20] - 2026-03-06 ### Bug Fixes - Handle Ctrl+C during bench catchup ([#297](#297)) <!-- generated by git-cliff --> </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). Co-authored-by: s2-release-plz[bot] <262023388+s2-release-plz[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Default append pipelining in s2-lite and remove the
S2LITE_PIPELINEgate (issue #48).This PR now includes the full durability/ack rework needed to make pipelining safe by default, plus broader wiring and test coverage.
What changed
await_durable=falseDurabilityNotifier:db.subscribe()task fan-outs durability progress to waiter callbacksCommandStateapplied points.S2LITE_PIPELINE--append-inflight-bytes(default128MiB)Tests
Dependency updates
tokio1.49 -> 1.50Refs #48