Closed satybald closed 7 years ago
This ultimately means the observer part of the processor isn't keeping up. 0.9.15.b1 is a beta release that tries to make this a bit easier by not configuring a custom event batch buffer size at all. That's based on multiple test runs with various buffer configurations and server params (seeing less retries and disconnect cycles over the period of an hour or more). It's counter-intuitive and the comment in https://github.com/dehora/nakadi-java/pull/299 is worth reading, but the short version is smaller underlying batch buffers seem to be more stable overall.
For a real world usecase maxUncommittedEvents, batchLimit and (maybe) batchFlushTimeout seem to be also worth tuning. Low maxUncommittedEvents especially seem to result in unstable client/server cycles, but a very high number can mean a consuming a backlog of events that won't be committable to the checkpointer because the session they were fetched under is expired.
The consumer protocol is quite complicated, I think too complicated. But an underlying thing seems to be to not consume large data sets from Nakadi unless the observer is very fast.
Closing for now. The default since 0.9.15 and up seems to be better and beyond that, it requires tuning based on factors like the observer's ability, rate of events, consumer configuration and hidden nakadi defaults, which are outside the client's ability to handle.
agree, after 0.15 release we didn't notice such exception for a while. thanks @dehora!
During using 0.13 version of the library we found that stream observer got stopped due to an exception. This happened on staging with eventlog subscription that has small number of events ~1000