You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Several changes need to be added - or checked that it does not impact - to client libraries
If the client detects that the connection is to a server v2.7.2+, the KV stream need to be created with the DiscardNew policy. The server version (json field "version") is present in the INFO protocol received during (re)connect.
Make sure that the check for heartbeat set on a consumer is at least 2x the heartbeat setting. The Go client had a bug when the check was set at the exact heartbeat value which could cause the library to think that the HB was missed.
For KV Watch, the library after creating the ordered consumer should have access to the consumer's "pending" number of messages at the time of the creation. As indicated with ADR-8, it is safer to use Pending+Delivered.Consumer, especially that servers have a bug when the consumer info's initial state may be wrong (Make sure we snapshot initial consumer info during consumer creation. nats-server#2858). Using ConsumerInfo's Pending + Delivered.Consumer will work for both old and new servers.
The pending value, if 0 when creating the watch, should trigger sending the "empty entry" to indicate that state. When the watcher starts to receive messages, if the init pending state was not already done, should keep track of the first time a message arrives and set the pending state to what the message delta is, then when the number of received messages is greater than this "initial pending" value, send the "empty entry" to signal that the initial state is reached.
Client authors please update with your progress. If you open issues in your own repositories as a result of this request, please link them to this one by pasting the issue URL in a comment or main issue description.
The text was updated successfully, but these errors were encountered:
Overview
Several changes need to be added - or checked that it does not impact - to client libraries
The pending value, if 0 when creating the watch, should trigger sending the "empty entry" to indicate that state. When the watcher starts to receive messages, if the init pending state was not already done, should keep track of the first time a message arrives and set the pending state to what the message delta is, then when the number of received messages is greater than this "initial pending" value, send the "empty entry" to signal that the initial state is reached.
Go PRs where those changes were implemented:
The behavior is documented in ADR-8.
Clients and Tools
Other Tasks
Implemented
Client authors please update with your progress. If you open issues in your own repositories as a result of this request, please link them to this one by pasting the issue URL in a comment or main issue description.
The text was updated successfully, but these errors were encountered: