Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on May 8, 2026. It is now read-only.
This repository was archived by the owner on May 8, 2026. It is now read-only.

Publisher flow control can block forever if a large message exceeds the bytes limit all by itself #685

Copy link
Copy link

Description

@plamut
Issue body actions

After reviewing the related Ruby PR and comparing it to the similar Python and Java implementations, I think the Java implementation is missing a corner case.

Suppose the publisher flow controller's byteLimit is set to 1000 bytes, and the desired behavior to Block. If a message larger than that arrives (say, 1200 bytes), it would block forever, because it would just reserve the maximum available capacity, but that would still not be enough to let it through. It would also cause all other messages to get stuck behind.

From what I can see, there's no check if a message would actually need to reserve more than byteLimit to get through?

Reactions are currently unavailable

Metadata

Metadata

Labels

api: pubsubIssues related to the googleapis/java-pubsub API.Issues related to the googleapis/java-pubsub API.priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.