Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add flush method to writer #1271

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

isaacd9
Copy link

@isaacd9 isaacd9 commented Mar 7, 2024

Add Flush method to writer.

The Flush method immediately writes the current batch to each partition no matter the batch size or timeout. This is useful to manage the Writer batching yourself. For instance, one might want to write 10 messages in series, and then force a flush, even if by default, the batch size would wait for 100 messages.

Flush holds the internal w.mutex when called.

This is part of the API suggested in #852, but only a piece of it.

@isaacd9 isaacd9 marked this pull request as draft March 7, 2024 21:04
@isaacd9 isaacd9 marked this pull request as ready for review March 7, 2024 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant