Skip to content

Conversation

@ischeinkman
Copy link
Contributor

Added a Buffer::check_can_flush method for checking if a Buffer can be flushed with Sender::flush.

Usecase

In our application we're operating in an async setting with a custom async HTTP library & writer. At the moment we need to isolate the QuestDB sending logic into its own set of threads because it doesn't expose enough information to be able to flush the Buffer ourselves. However, by including this check_can_flush call we can now recreate the entirety of Sender::flush_impl using our custom library and async system.

@CLAassistant
Copy link

CLAassistant commented May 7, 2025

CLA assistant check
All committers have signed the CLA.

@ideoma ideoma changed the title Allow external Buffer flushability checking chore: allow external Buffer flushability checking May 7, 2025
@amunra
Copy link
Collaborator

amunra commented May 9, 2025

Fair :-)

What HTTP library are you using, out of curiosity?

@amunra amunra merged commit 5408aa0 into questdb:main May 9, 2025
11 checks passed
@amunra
Copy link
Collaborator

amunra commented May 9, 2025

I've merged this PR, but note that we're adding array support soon which will also introduce new minor breaking changes to the API. Some of these have already been introduced in the main branch.

As such I'll delay releasing version 5.0.0 until those changes are ready.
For now, you should be able to use the questdb-rs dependency tied to the specific commit:

[dependencies]
questdb-rs = { git = "https://github.com/questdb/c-questdb-client", rev = "5408aa05ea9a5f16cbadc4f6c585cd6f8e8034d3" }

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.

4 participants