tigerbeetle-rust / tigerbeetle-unofficial

Safe bindings to tigerbeetle client
Apache License 2.0
43 stars 8 forks source link

Prevent dropping client from inside of callback #4

Closed zetanumbers closed 1 year ago

zetanumbers commented 1 year ago

It's possible to drop client from inside of the on_completion callback, potentially deadlocking client drop.

zetanumbers commented 1 year ago

Client now waits for requests to finish, and droping it from callback deadlocks tigerbeetle thread. No unsafe behaviour, and it is not clear what to do upon detecting this.