Redis version: 5.0.7

Assuming a client does:

BLPOP l 60000

And then a background thread of some module performs:

RM_Lock();
RM_Call("lpush", "l", "1");
RM_Unlock();

The blocked client does not free and stays blocked.

Comment From: guybe7

currently we decide to unblock clients (if possible) in processCommand - which isn't called in case of a module thread issuing an RM_Call the obvious solution is to add

if (listLength(server.ready_keys))
    handleClientsBlockedOnKeys();

in RM_Call... but that creates another issue: what if we are in MULTI/EXEC? we only want to unblock clients after the EXEC

Comment From: MeirShpilraien

@guybe7 what if we will do it on RM_ThreadSafeCtxUnlock?