Skip to content

Better workflow for leadership change while pull consuming. #1313

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 12, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Better workflow for leadership change while simplified consuming.
  • Loading branch information
scottf committed May 12, 2025
commit c3a5f4ee9fb2fecda76a4fae12cd14703a0c6211
Original file line number Diff line number Diff line change
Expand Up @@ -130,19 +130,20 @@ protected Message _nextUnmanagedNoWait(String expectedPullSubject) throws Interr
case MESSAGE:
return msg;
case STATUS_TERMINUS:
// if the status applies return null, otherwise it's ignored, fall through
// if the status applies, return null, otherwise it's ignored, fall through
if (expectedPullSubject == null || expectedPullSubject.equals(msg.getSubject())) {
return null;
}
break;
case STATUS_ERROR:
// if the status applies throw exception, otherwise it's ignored, fall through
// if the status applies, throw exception, otherwise it's ignored, fall through
if (expectedPullSubject == null || expectedPullSubject.equals(msg.getSubject())) {
throw new JetStreamStatusException(msg.getStatus(), this);
}
break;
}
// Check again when, regular messages might have arrived
// These statuses don't apply to the message that came in,
// so we just loop and move on to the next message.
// 1. Any STATUS_HANDLED
// 2. STATUS_TERMINUS or STATUS_ERRORS that aren't for expected pullSubject
}
Expand Down
Loading
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy