Skip to content

Conversation

@SpeedyCoder
Copy link
Contributor

This gives the user more control on how often the sink will flush.
Using ticker instead of timer makes the implementation simpler and makes sure messages gets flushed periodically.

@mjgarton
Copy link
Contributor

mjgarton commented May 1, 2019

This looks like it will:

  • flush even if there is nothing to flush
  • potentially flush after very few entries, just as an accident of where the ticker is and when the writes start compared to that.

Is this what we want?

@SpeedyCoder
Copy link
Contributor Author

Ah yeah, I will fix the first bit. The second one is more of a question about what behaviour we want. With the old implementation if we kept writing 2 messages per second then it might end up flushing only after 8.5 minutes, so it might take this long to get an acknowledgement back. With this implementation the longest time to get an acknowledgement is 1 second by default or whatever you specify.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants