In later versions of the Google PubSub client Java API, they have added a maxOutstandingElementCount
value which defaults to 1000.
maxOutstandingElementCount -- The maximum number of elements that can be outstanding before data flow is restricted, or null if there is no specified limit.
We are using PubSub in a transactional system and are trying to only acknowledge the messages at a certain point in the future when the transactions have been globally committed. The problem is that we don't always know beforehand the number of records that we want to be outstanding since the transactions can be based on time or customer logic.
Question: What are the ramifications of setting the max-outstanding value to be null
or some large integer? Does this only impact client side memory storage of outstanding GUIDs or other telemetry? Anything else we need to worry about?
We already have our own flow-control since the receiver threads write to bounded blocking queues but we may have 10k or even 100k outstanding messages depending on client settings and we want to make sure that setting max-outstanding to null
is valid.
Thanks for any information.