3 ms·
There’s a memcached client that uses connection pools but it has its own set of problems. And you have to use nginx plus to get the backpressure support on the
by hinkley 7y ago
There’s a memcached client that uses connection pools but it has its own set of problems.
And you have to use nginx plus to get the backpressure support on the ingest side. If my levels of capability and capacity were a little higher I’d be tempted to start writing a reverse proxy in Rust.
- namibj 7y agoCan't you just use an atomic counter for requests/responses per connection, and increment/decrement it when you receive/send a packet, checking that it is positive before you try to send, and being fine if it briefly dips into the negative region because there shouldn't be too many fighting over being able to queue request? And even if, you should be able to find instructions or so that do a bounded-decrement that does not go below zero, and still ensures that no count are lost.