You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "merlimat (via GitHub)" <gi...@apache.org> on 2026/04/29 17:24:14 UTC
[PR] [test][client] PIP-468: V5 StreamConsumer disconnect / reconnect / past-grace reassignment [pulsar]
merlimat opened a new pull request, #25619:
URL: https://github.com/apache/pulsar/pull/25619
## Summary
Two new V5 StreamConsumer multi-consumer dynamics tests, plus a small broker config to make them fast.
### Tests
- **`testStreamConsumerReconnectWithinGraceKeepsAssignment`** — alice + bob share a 4-segment topic. Close alice's consumer and re-subscribe with the same `consumerName`. The controller re-attaches to the existing session by name (no rebalance, no churn on bob). Same key set across both batches confirms each consumer keeps its segments.
- **`testStreamConsumerDisconnectPastGraceTriggersReassignment`** — same setup, but alice's underlying connection is severed (close her dedicated client) and she stays away past the grace period. Bob ends up serving every key in the second batch. Drain runs concurrently with the rebalance — no `Thread.sleep` between disconnect and produce.
### Wiring
- `ServiceConfiguration.scalableTopicConsumerSessionGracePeriodSeconds` (default 60s, matching the previous hard-coded value).
- `ScalableTopicController.createCoordinator` reads it and passes it to `SubscriptionCoordinator` instead of using the static default.
- `SharedPulsarCluster` sets it to 2s so reassignment-after-disconnect can be exercised in seconds rather than a minute.
## Test plan
- [x] `./gradlew :pulsar-broker:test --tests \"org.apache.pulsar.client.api.v5.V5MultipleConsumersTest\"` — all 5 tests pass; new tests run in ~2.2s and ~3.3s.
## Matching PR
- [ ] No matching PR.
### area/test
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [feat] PIP-468: V5 StreamConsumer disconnect / reconnect / past-grace reassignment [pulsar]
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari merged PR #25619:
URL: https://github.com/apache/pulsar/pull/25619
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org