questdb / c-questdb-client

Rust, C and C++ client for QuestDB InfluxDB Line Protocol
Apache License 2.0
48 stars 13 forks source link

BREAKING CHANGE: Splitting buffer API from sender API #15

Closed amunra closed 2 years ago

amunra commented 2 years ago

The API for connecting and sending messages has been split from that used to construct ILP buffers.

This allows embedding the library in more complex use cases where an application might have multiple producers of ILP messages and only a single thread maintaining the connection to a QuestDB server.

Another use case might be to send the same ILP buffers to multiple QuestDB servers concurrently.

Buffers are re-usable and cleared automatically when calling .flush(buffer). If you want to keep the buffers around, call .flush_and_keep(buffer) instead.