- private async startOnEmptyQueue (): Promise<void> {
- if (
- this.onEmptyQueueCount > 0 &&
- (this.usage.tasks.executing > 0 || this.tasksQueue.size > 0)
- ) {
- this.onEmptyQueueCount = 0
- return
- }
- (this.onEmptyQueue as EmptyQueueCallback)(this.info.id as number)
- ++this.onEmptyQueueCount
- await sleep(exponentialDelay(this.onEmptyQueueCount))
- await this.startOnEmptyQueue()
+ /** @inheritdoc */
+ public deleteTaskFunctionWorkerUsage (name: string): boolean {
+ return this.taskFunctionsUsage.delete(name)