Skip to content

Port restate-0.51.1 fork commits onto the v0.53.0 release - #26

Open
tillrohrmann wants to merge 9 commits into
masterfrom
upgrade/v0.53.0
Open

tillrohrmann wants to merge 9 commits into
masterfrom
upgrade/v0.53.0

Conversation

@tillrohrmann

@tillrohrmann tillrohrmann commented Sep 18, 2026

Copy link
Copy Markdown

Ports the Restate patch stack up to restate-0.51.1 (5df796c, Restate's current pin) onto upstream v0.53.0 (c8b2e2c).

Scope. The three commits between restate-0.51.1 and restate-0.51.4 (custom SST partitioner callbacks 8b3d698, SstFileManager::new_with_env 1179e8d, UnindexedWriteBatch 65bc9c1) are deliberately excluded and will be ported in a follow-up.

Carried (no upstream equivalent in v0.53.0): compact CF map keys, callback-based table-properties collectors with need_compact and keyed property lookup, shareable RateLimiter, vectored put/merge on WriteBatchWithIndex, lazy unfiltered CF metadata (get_column_family_metadata{,_cf}_ref), the Restate C overlay.

Replaced by upstream APIs: WriteBatch vectored ops (now fallible), savepoints (set_save_point/rollback_to_save_point), single_delete on both batch types, fixed-prefix partitioner (SstPartitionerFactory::fixed_prefix), ReadOptions::set_table_filter.

See PORT_REVIEW.md for the per-commit disposition and the non-mechanical changes to review, and RESTATE_PATCHES.md for consumer migration notes and validation results.

Local validation: fmt, cargo check --locked, strict clippy, cargo nextest run --workspace (503 passed) and with multi-threaded-cf,jemalloc,raw-ptr,serde1 (528 passed), doctests (117 passed).

🤖 Generated with Claude Code

@tillrohrmann

Copy link
Copy Markdown
Author

@codex review

@tillrohrmann
tillrohrmann force-pushed the upgrade/v0.53.0 branch 2 times, most recently from 2a07547 to 2008fdb Compare September 18, 2026 13:51
@tillrohrmann tillrohrmann changed the title Port fork commits onto latest v0.53.0 release Port restate-0.51.1 fork commits onto the v0.53.0 release Sep 18, 2026
@tillrohrmann
tillrohrmann force-pushed the upgrade/v0.53.0 branch 5 times, most recently from 51b600e to 260da50 Compare September 22, 2026 10:30
AhmedSoliman and others added 8 commits September 22, 2026 13:06
Combine the original compact-key change d1d638b and cf_names fix c43d930 with the 0.53 adaptations from 76bcf22.

Include the lockfile update and compact-key conversions for new CF creation and failed-drop recovery paths so this commit builds independently. The unrelated rate-limiter test import fix belongs to the rate-limiter commit.

Export CompactString from the crate root: it appears in ThreadMode's method signatures, so it is part of the public API rather than an incidental leak of the smartstring type.

Co-authored-by: Pavel Tcholakov <pavel@restate.dev>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Port 3b51769, preserving upstream imports and exports.

Fold the ColumnFamilyMetaData test import repair from 76bcf22 into this commit so all targets build immediately after introducing RateLimiter. The cross-DB test is a smoke test: the C API exposes no rate-limiter accounting to assert sharing on.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Carry 90bf693, 009033b, 0ed4b45, and the property-lookup part of the C overlay from 120a129. Use upstream table filters and borrowed property handles. Keep only the nine C functions the Rust collector and user-property lookups need; omit the duplicate upstream bindings, unused SST-reader/collection APIs, legacy getters, and their ownership machinery. Require shared thread-safe factory callbacks and guard empty slices and unknown entry types.

Factories return Option<Collector> so they can decline a table, which RocksDB honours by skipping every collector callback for that file. User-collected property inserts use last-write-wins instead of silently keeping the first value.

Keep the FlushJobInfo CStrLike interface and use bake() to avoid conversion allocations for borrowed C strings. Document invalid-input panics and cover string/owned/borrowed inputs, returned-value lifetimes, and allocation counts in real flush callbacks.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Port 5d8e58c, retaining upstream allocator and iterator lifetime fixes. Document internal concatenation and check FFI part counts. One private helper marshals the pointer and length arrays for all four methods.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Adapt 3fe39d5 and its export fix 6ee35eb. get_column_family_metadata{,_cf} keep upstream's return type name, ColumnFamilyMetaData, but it is now the source fork's lazy snapshot: totals through name(), size(), and file_count(), plus level() and levels() that preserve empty levels and create level handles on demand, reusing upstream's shared ownership of level and file metadata. The eager struct with public fields is gone.

Unlike the source fork, the type carries no lifetime and drops the Ref suffix. RocksDB copies the metadata when the snapshot is taken, and upstream's child handles already outlive the DB, so tying only the root to the DB borrow restricted callers without adding safety.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The fork's own single_delete{,_cf} implementation for indexed batches
(8aaa2b7) is replaced by upstream's methods; keep its behavioral tests so
the replacement is verified on 0.53.0.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
RocksDB 11.8.1's WriteBatchWithIndex::DeleteRange returns NotSupported and the C wrappers discard that status, so delete_range and delete_range_cf record nothing and report nothing. Mark them deprecated so callers get a compile-time warning instead of silent data retention, and pin the behaviour with a test that fails once a port makes them work. The proper fix travels with the deferred UnindexedWriteBatch port.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Records the maintenance/release process, the per-commit disposition of the
restate-0.51.1 patch stack on v0.53.0, evidence for every implementation
replaced by an upstream API, and consumer migration notes. The workflow lives
in RESTATE_PATCHES.md; the upstream README only gains a short pointer, so
upstream README changes rebase without conflicts. The three commits between
restate-0.51.1 and restate-0.51.4 are listed as deferred to a follow-up port.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Replace the broken Pagure git-snapshot URL with the verified libaio
0.3.113 release archive, updating its checksum and extraction directory.

Patch the pinned Folly getdeps downloader to check wget exit status and
show HTTP/TLS diagnostics instead of reporting an empty-file checksum
mismatch. Set download timeouts and retry limits, invalidate the Folly CI
cache, and require the patch in the root crate package.
@tillrohrmann

Copy link
Copy Markdown
Author

@AhmedSoliman I'll let you commandeer this PR. Feel free to discard it if it doesn't help doing the porting to 0.53.0 faster.

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.

2 participants