Skip to content

Verify RabbitMQ Streams locator checkpoints after consumer close - #1751

Merged
thomhurst merged 1 commit into
mainfrom
issue-49-stream-checkpoints
Dec 3, 2026
Merged

thomhurst merged 1 commit into
mainfrom
issue-49-stream-checkpoints

Conversation

@thomhurst

Copy link
Copy Markdown
Owner

RabbitMQ.Stream.Client 1.13.0 can store the last processed offset through the locator after the reliable consumer closes. This PR verifies that path on a standard stream and on both partitions of a super stream. The test receives a real message on each stream, closes the consumer, and checks that an absent checkpoint becomes the delivered offset.

The startup diagnostic points to Relayer #316 for the remaining graceful shutdown requirement. The upstream maintainer closed the report after showing how to checkpoint through the locator. Applications still have to wait for their own callbacks. The transport guide now describes that distinction. Upstream resolution

The Pulsar guide also links the strict Native AOT byte-message reproduction for Pulsar.Client 3.21.0. DotPulsar 5.3.4 and Pulsar.Client 3.21.0 remain the released versions covered by the existing probes. Pulsar.Client diagnostics

Scope

Refs #49, #315 and #316. This delivers checkpoint coverage and transport status corrections that can ship independently. Both adapter issues remain open for message execution and conformance. Other open transport telemetry reports exercise different message paths and require separate validation.

The tests reuse Relayer's topology registration and shared RabbitMQ fixture, the native reliable producer and consumer, and native locator offset storage and lookup. Per-message cost is unchanged. The production change affects only the startup configuration error.

Validation

  • RabbitMQ 4.1.4 with RabbitMQ.Stream.Client 1.13.0. All 15 focused cases passed on each of .NET 10 and .NET 11, including both checkpoint topologies.
  • Curb formatting and checks passed for all changed C# files.
  • The documentation site passed npm ci and npm run build.

@coderabbitai

coderabbitai Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 180b664b-8991-4cd3-9b6a-fa35d8cb893d
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@thomhurst

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-12-03T21:29:18.624869Z f4dbd0d Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: f4dbd0da2f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@github-actions

github-actions Bot commented Dec 3, 2026

Copy link
Copy Markdown

Review of PR 1751 at the current head.

Verdict: no blocking issues.

  • The production change only rewords the startup NotSupportedException. It does not point at the closed upstream issue any more, and ConfigurationTests is updated to match. There is no per-message cost.
  • The docs now say what the upstream maintainer said: check the offset through the locator, and the caller owns callback completion. The Pulsar.Client AOT note is scoped to a released version and links its reproduction. I did not run npm run build, so the links and anchors are unchecked here.
  • LocatorCheckpointTests uses the shared broker fixture and isolated names. It has no limiter attributes and it cleans up the producers and the consumer in finally blocks.

Non-blocking note: the test checks that StoreOffset and TryQueryOffset work on an open StreamSystem after consumer.Close(). It does not exercise the race the docs describe, where Close() returns while a handler is still running. The offset is also stored after the receive loop, so it would pass even without the close. That is enough to back the 'works through the locator' claim. If you want it to pin the shutdown behavior, hold a handler open across Close() and store the offset from the handler afterwards.

@thomhurst

Copy link
Copy Markdown
Owner Author

The callback-race suggestion in the review belongs with #316, which tracks draining in-flight handlers. This PR tests a narrower guarantee on the standard stream and both super-stream partitions. After the consumer closes, the locator can store the delivered offset and read it back. The tests cover that guarantee as written.

Validated the SHA-256 manifest for all five archived files, including both framework test reports and the documentation build log. The archive is at Relayer-evidence/pr-1751/f4dbd0da2fcaf0505f16c3145679e9ee7e0e7be4/ on the validation host while this PR is open.

@thomhurst
thomhurst marked this pull request as ready for review December 3, 2026 21:27
@thomhurst
thomhurst enabled auto-merge (squash) December 3, 2026 21:28
@thomhurst
thomhurst merged commit f1e6c7c into main Dec 3, 2026
20 checks passed
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.

1 participant