Skip to content

Websocket API should support cumulative acknowledgement #5979

@jeffgrunewald

Description

@jeffgrunewald

Is your feature request related to a problem? Please describe.
In order to support feature parity with other clients, the WebSocket should also be able to cumulatively acknowledge messages up to and including the supplied message ID.

Describe the solution you'd like
Ideally, the acknowledgement payload that currently only seems to support {"messageId":"CAoQKA=="} could accept an optional second field specifying individual acknowledgement or cumulative acknowledgement. The absence of the field could be assumed to equate to individual acknowledgement. As an example, the following two options could be accepted to allow for individual acknowledgement of a message:
{"messageId":"CAoQKA=="} or {"messageId":"CAoQKA==","ackType":"Individual"}
while the following would be required to acknowledge messages cumulatively:
{"messageId":"CAoQKA==","ackType":"Cumulative"}

Describe alternatives you've considered
Perhaps a topic-level setting would also work in which case only it would be required at topic configuration as with partitioned topics but I image that would require more work to support.

Additional context
In order to maximize throughput of messages across a WebSocket, particularly when the same socket connection is handling acknowledgement, it would be ideal to support cumulative acknowledgement to minimize the processing on the cluster side by minimizing the number of acknowledgement messages needed to keep data flowing to the consumer, while also minimizing the amount of bottlenecking that occurs within the socket client itself by not requiring a one-for-one ack message to received message.

Thanks very much!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions