摘要 |
A system and a method are disclosed for managing file locks, including initiating, by a processing device executing a kernel, executions of a number of active tasks that each has acquired a respective lock to a record, and in response to release of a first lock to the record by an active task, waking up a previously-designated worker task out of a number of idle tasks, in which the worker task is to attempt an acquisition of a second lock on behalf of at least one remaining task of the idle tasks. |
主权项 |
1. A method comprising:
initiating, by a processing device executing a kernel, execution of an active task that has acquired a first lock to a record, wherein a plurality of idle tasks are waiting to access the record, and wherein one of the plurality of idle tasks was previously designated as a worker task; in response to releasing, by the active task, the first lock to the record, waking up the designated worker task out of the plurality of idle tasks; and attempting, by the designated worker task, an acquisition of a second lock on behalf of at least one of the remaining plurality of idle tasks. |