-
Notifications
You must be signed in to change notification settings - Fork 227
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
Issues with explicitely ack()
messages remaining in queue
#1856
Comments
@PILLOWPET Did you try |
Hello @feywind, I work with @PILLOWPET on the same project and I managed to narrow down the issue. Even without shutting down the app we can see that the message is not removed from the subscription. Actually in our tests we only shut down the app to make sure that all the messages in the queue are pulled again after restarting it. I noticed that this issue (being able to receive messages but not to acknowledge them) occurs depending on the number of active subscriptions we have in our app, if we have a number of 20 or above active subscriptions in our app the acknowledgment does not work as expected, if we have a number 19 or under active subscriptions it works fine. It may be also worth to mention that we, currently for this app, have for each distinct subscription - one distinct associated topic. |
Looks like this: #1705 and this behaviour is also mentioned here https://cloud.google.com/nodejs/docs/reference/pubsub/latest/pubsub/subscription-class We will try to implement a fix using the links mentioned above to see if it fixes our issue but if that is the case I believe that the library should raise a warning or an error when the maximum number of stream is reached or exeeded. |
I agree that that's annoying. I'll have to check with the other language authors, because we're trying to keep them more in sync going forward, but it seems like a reasonable request. |
Closed in favour of #1917 |
Environment details
@google-cloud/pubsub
version: 4.0.7Steps to reproduce
Post
endpoint n my app that emits one eventmyEvent
to a given topicfoo
on PubSub.bar
subscription that is supposed to change a field in my databasemessage.ack()
and then the function finishes.There is likely something that I'm missing, I don't have exactly once delivery enabled but I don't understand why a message that I explicitely
ack
remains in the queue and is sent again when I add my subscription again to the topic by relaunching the app.My PubSub options:
Thanks!
The text was updated successfully, but these errors were encountered: