mirror of
https://github.com/fluencelabs/redis
synced 2025-06-17 19:21:21 +00:00
Threaded IO: ability to disable reads from threaded path.
This commit is contained in:
@ -2723,6 +2723,7 @@ int handleClientsWithPendingWritesUsingThreads(void) {
|
||||
* pending read clients and flagged as such. */
|
||||
int postponeClientRead(client *c) {
|
||||
if (io_threads_active &&
|
||||
server.io_threads_do_reads &&
|
||||
!(c->flags & (CLIENT_MASTER|CLIENT_SLAVE|CLIENT_PENDING_READ)))
|
||||
{
|
||||
c->flags |= CLIENT_PENDING_READ;
|
||||
@ -2734,7 +2735,7 @@ int postponeClientRead(client *c) {
|
||||
}
|
||||
|
||||
int handleClientsWithPendingReadsUsingThreads(void) {
|
||||
if (!io_threads_active) return 0;
|
||||
if (!io_threads_active || !server.io_threads_do_reads) return 0;
|
||||
int processed = listLength(server.clients_pending_read);
|
||||
if (processed == 0) return 0;
|
||||
|
||||
|
Reference in New Issue
Block a user