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
Right now, using relative offsets Offset::from_beginning(X) or Offset::from_end(X) when fetching from a partition have undesirable behavior when X is greater than the number of records in that partition. When this happens, a stream request will just hang. Instead, I think that the relative offset resolution should be saturating, meaning that:
If n is the size of the partition, then
When we fetch using Offset::from_end(X) and X > n, then the fetch should resolve to absolute offset 0
When we fetch using Offset::from_beginning(X) and X > n, then the fetch should resolve to absolute offset X-1
The end result of this is that no call to fetch should ever cause the client to hang.
Right now, using relative offsets
Offset::from_beginning(X)
orOffset::from_end(X)
when fetching from a partition have undesirable behavior when X is greater than the number of records in that partition. When this happens, a stream request will just hang. Instead, I think that the relative offset resolution should be saturating, meaning that:If
n
is the size of the partition, thenOffset::from_end(X)
andX > n
, then the fetch should resolve to absolute offset0
Offset::from_beginning(X)
andX > n
, then the fetch should resolve to absolute offsetX-1
The end result of this is that no call to
fetch
should ever cause the client to hang.Related: #1007
The text was updated successfully, but these errors were encountered: