(workerId: number, data: any)
| 302 | } |
| 303 | |
| 304 | private handleWorkCompletion(workerId: number, data: any): void { |
| 305 | this.cleanupWorkerAssignment(workerId); |
| 306 | |
| 307 | if (data.type === "chunk") { |
| 308 | this.handleChunkCompletion(data.chunkId, data.success); |
| 309 | } else if (data.type === "job") { |
| 310 | this.checkJobCompletion(data.jobId); |
| 311 | } |
| 312 | |
| 313 | const worker = this.workerThreads.get(workerId); |
| 314 | if (worker) { |
| 315 | worker.postMessage({ type: "requestWork" }); |
| 316 | } |
| 317 | } |
| 318 | |
| 319 | private handleProgressUpdate(data: any): void { |
| 320 | if (data.chunkId) { |
no test coverage detected