Ack deadline for this subscription is set to 120 seconds. I see duplicates in logs more than 30000 times. Oldest entity in Memcached is also > 16h so problem not in deduplication. Any ideas why do I observe such weird behavior?
Hi,Yes I made sure all the request returns 200 response in less than 15 seconds (according to google statistics 99% - 8307 ms, 98% - 2709 ms) but it doesn't seem to help. We wrote simple test - created endpoint that emulates processing by simply sleeping for some time and here is what we've seen:1. Sent 11 messages to Pub/Sub:a. If processing time is 11 sec - no duplicates
b. If processing time is 12 sec - starting to send duplicatesc. If we send 12 messages with 11 sec processing time - starting to send duplicates
2. Sent 20 messages to Pub/Sub:a. If processing time is 9 sec - no duplicates
b. If processing time is 10 sec - starting to send duplicatesc. If we send 21 messages with 9 sec processing time - starting to send duplicates
For processing time 1s we are able to handle around 70 messages - then we will start to receive duplicates. Pub/Sub behavior seems to be kind of unpredictable to me. I've read about slow start algorithm - but I don't observe it in logs. In all cases described above we sent bulk of messages to Pub/Sub and then Pub/Sub sends all messages to our endpoint. Even though we send 200 response for each of message for some reason Pub/Sub thinks that some of messages were undelivered and resends whole bulk again. Could you please clarify a bit what could be reason of such behavior and maybe provide some little insight how Pub/Sub works?
P.s. Ack deadline - 120 secondsRegards,Alexey
On Tuesday, January 26, 2016 at 7:49:12 PM UTC+2, Kamal Aboul-Hosn wrote:Hi, Alexey,Receiving duplicates should generally be rare assuming the acknowledgements are being sent back to the server correctly and in time. Can you please confirm that you are responding to the received push messages with an appropriate HTTP status code (200-204, 102) in less time than the ack deadline? More information is available in the subscriber documentation under "Receiving push messages."Thanks!Kamal
On Tuesday, January 26, 2016 at 3:44:39 AM UTC-5, Alexey Duzhiy wrote:Hi,I have following application configuration:Cloud Pub/Sub -----> 1 B4 instance (message processor)I'm using push subscription. I'm testing throughput of this pair by supplying 3000 messages to topic which then pushed to message processor. Message processor performs some computations and save them to datastore. I use Google Memcached and Pus/Sub message_id to prevent duplicates received from Cloud Pub/Sub. I've read in lot of places that duplicates are rarely possible. But in my case I'm still receiving duplicates after > 16h. I left test to run overnight and here is what monitoring console shows me:
Ack deadline for this subscription is set to 120 seconds. I see duplicates in logs more than 30000 times. Oldest entity in Memcached is also > 16h so problem not in deduplication. Any ideas why do I observe such weird behavior?
--
You received this message because you are subscribed to the Google Groups "Google Cloud Pub/Sub Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cloud-pubsub-dis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/cloud-pubsub-discuss/c86d0ede-1bbc-47f3-9794-8ac845ce0672%40googlegroups.com.