Skip to content
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

[FIXED] JetStream: Ordered consumer issues #600

Merged
merged 1 commit into from
Oct 6, 2022
Merged

Conversation

kozlovic
Copy link
Member

@kozlovic kozlovic commented Oct 5, 2022

  • It would reset when receiving hearbeats due to a bug on how I was checking for sequence mismatch (overriding ldseq/sseq/etc..)
  • On reset, the consumer configuration would not be the same than the original. That was because I was not making a copy of the original consumer config.

Signed-off-by: Ivan Kozlovic ivan@synadia.com

@kozlovic kozlovic requested review from aricart and ColinSullivan1 and removed request for aricart October 5, 2022 23:04
@@ -1538,6 +1538,7 @@ jsSub_processSequenceMismatch(natsSubscription *sub, natsMsg *msg, bool *sm)
jsSub *jsi = sub->jsi;
const char *str = NULL;
int64_t val = 0;
struct mismatch *m = &jsi->mismatch;
Copy link
Member Author

Choose a reason for hiding this comment

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

No, this is a pointer to an internal structure (take the address of). I could have name those fields say "mldseq", etc.. but decided to make them part of a struct.

Copy link
Member

@ColinSullivan1 ColinSullivan1 left a comment

Choose a reason for hiding this comment

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

LGTM.

- It would reset when receiving hearbeats due to a bug on how
I was checking for sequence mismatch (overriding ldseq/sseq/etc..)
- On reset, the consumer configuration would not be the same
than the original. That was because I was not making a copy
of the original consumer config.

Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
@kozlovic kozlovic merged commit 33b9598 into main Oct 6, 2022
@kozlovic kozlovic deleted the fix_ordered_cons branch October 6, 2022 00:06
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.

None yet

2 participants