-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Google-pubsub: ACK msgs when acknowledged by publisher #14715
Conversation
Pinging @elastic/siem (Team:SIEM) |
a71e161
to
5beae0c
Compare
@@ -152,15 +160,11 @@ func (in *pubsubInput) run() error { | |||
// Start receiving messages. | |||
topicID := makeTopicID(in.ProjectID, in.Topic) | |||
return sub.Receive(ctx, func(ctx context.Context, msg *pubsub.Message) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any impact of letting the func
return without an Ack/Nack()
(is there an impact of not handling the message synchronously in f
)? I wonder if it affects the accounting used to track MaxOutstandingMessages/MaxOutstandingBytes. Or if it affects the automatic ACK deadline extension of the message. The docs for Receive
aren't 100% clear to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the docs aren't too clear. My understanding is that it will only affect the ACK deadline if it gets ACK'd at a later time (before re-transmission).
In my tests (against gcloud, not the emulator) a non-ACKed message gets re-delivered eventually after a few minutes. Nack() just causes it to redeliver more quickly.
Update the google-pubsub input to only ACK received events when an ACK from the internal publisher is received. Closes elastic#13346
5beae0c
to
831c544
Compare
jenkins, test this |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Update the google-pubsub input to only ACK received events when an ACK from the internal publisher is received. Also removes the Beta label from the input docs. Closes elastic#13346 (cherry picked from commit 2ec17cc)
Update the google-pubsub input to only ACK received events when an ACK from the internal publisher is received. Also removes the Beta label from the input docs. Closes elastic#13346 (cherry picked from commit 2ec17cc)
Update the google-pubsub input to only ACK received events when an ACK
from the internal publisher is received.
Also removes the Beta label from the input docs.
Closes #13346