Skip to content

Auto-enable vqueues on leader transition when config flag is set#4777

Merged
tillrohrmann merged 2 commits into
restatedev:mainfrom
tillrohrmann:enable-vqueues-version-barrier
May 21, 2026
Merged

Auto-enable vqueues on leader transition when config flag is set#4777
tillrohrmann merged 2 commits into
restatedev:mainfrom
tillrohrmann:enable-vqueues-version-barrier

Conversation

@tillrohrmann
Copy link
Copy Markdown
Contributor

When a partition becomes leader and Configuration::common::experimental
has is_vqueues_enabled() set, propose a VersionBarrierCommand carrying
PartitionFeatureChange::EnableVqueues — but only if the FSM hasn't already
recorded the opt-in. The persisted state update flows through the existing
OnVersionBarrierCommand apply path; become_leader does not touch the FSM
mirror locally.

@tillrohrmann tillrohrmann requested a review from AhmedSoliman May 20, 2026 21:52
Copy link
Copy Markdown

@claude claude Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

tillrohrmann and others added 2 commits May 21, 2026 23:55
Extend the StateMachineFeatures trait with is_vqueues_enabled (gated on the
persisted feature flag) and move the impl from SemanticRestateVersion to
StateMachine + StateMachineApplyContext so each method can consult both the
min Restate version and the persisted feature set. Replace the in-state-machine
Configuration::pinned().common.experimental.is_vqueues_enabled() call sites
with self.is_vqueues_enabled() / ctx.is_vqueues_enabled().

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
When a partition becomes leader and Configuration::common::experimental
has is_vqueues_enabled() set, propose a VersionBarrierCommand carrying
PartitionFeatureChange::EnableVqueues — but only if the FSM hasn't already
recorded the opt-in. The persisted state update flows through the existing
OnVersionBarrierCommand apply path; become_leader does not touch the FSM
mirror locally.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@tillrohrmann tillrohrmann force-pushed the enable-vqueues-version-barrier branch from 8573509 to 1ff7d8c Compare May 21, 2026 22:01
@tillrohrmann tillrohrmann merged commit 1ff7d8c into restatedev:main May 21, 2026
28 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators May 21, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants