Conversation
|
This looks good and useful semantically. What I'm not sure of is whether the length of the queue should be calculated here or inside |
|
@avanov Thanks for the review. I did it like this because I also plan to add |
|
@steve-chavez yeah I get that from the linked discussion, though aren't they two different concepts? One has to do with a "peekable" stat value (property of the queue), another has to do with utilising all available underlying stats for higher level interface of back-pressuring (back-pressuring being a property of the queue). For instance, the following sequence: it assumes that push always leads to (+1) for the stat value, and that |
|
@avanov Sorry for the late reply here. Since the newest hasql-pool doesn't use resource-pool(ref), I no longer need this change(we're transitioning to the newest hasql-pool PostgREST/postgrest#2391). |
Hello @avanov ,
As mentioned in bos#42 (comment), I'd like to limit the waiter queue to do backpressure. So I've added
totalWaiterstoPoolStats.Related: PostgREST/postgrest#2042 (comment)
LMWYT, thanks!