Draft
Conversation
SuperCuber
commented
Apr 9, 2025
| (if (seq records) | ||
| (run! put! records) | ||
| ; Throws exception if not connected | ||
| (.listTopics consumer (Duration/ofMillis 5000))) |
Author
There was a problem hiding this comment.
add one more timeout field to the config perhaps?
| (loop [] | ||
| (when-let [records (poll!)] | ||
| (run! put! records) | ||
| (if (seq records) |
Author
There was a problem hiding this comment.
this means an additional listTopics network call every time an empty poll is received. Might have performance/load implications? I doubt it, since it only happens when 0 lag and the call should be pretty lightweight.
| (:ketu.source/consumer-thread state)) | ||
|
|
||
| (defn closed? [consumer] | ||
| (-> consumer :ketu.source/out-chan async-protocols/closed?)) |
SuperCuber
commented
Apr 9, 2025
| (run! put! records) | ||
| (if (seq records) | ||
| (run! put! records) | ||
| ; Throws exception if not connected |
Author
There was a problem hiding this comment.
do we want automatic recovery? or does it belong in the application / wrapper library?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goals:
Maybe: Automatic recovery from the error