Roeder

Results 6 comments of Roeder

> the pool is created upon the first request But uvicorn is asynchronous, and if the db initialization is placed in the `__call__`, `asyncio.Lock` is required when requests come in,...

@martyanov > aetcd is mostly a thin wrapper over native gRPC transport used by etcd Yeah, but I suspect that the frequent creation of stream-stream requests is more stressful for...

> All the operations share one single channel and connection Indeed, all requests share a channel, but I think that since ETCD has designed LeaseKeepalive as a two-way stream method,...

And it’s possible to move the `_lock` at line 233 in `producer.py` to function `_get_or_create_publisher`? Maybe `_lock` is only required when `_send_batch` needs to create a new publisher. In addition,...

Here is a simple wrapper for Producer, with the following modifications: 1. remove `_buffered_messages_lock` 2. move `_lock` into `_get_or_create_publisher` 3. add `_buffered_sub_entry_messages` 4. remove the arg `sync` from `_send_batch` 5....

Here is a scenario: `_timer` blocks at `writer.drain()`, and at this point there are a lot of other tasks calling `send` concurrently. These tasks must wait `_timer` because of this...