MCPcopy Index your code
hub / github.com/nodejs/node / removeWorker

Function removeWorker

lib/internal/cluster/primary.js:142–150  ·  view source on GitHub ↗
(worker)

Source from the content-addressed store, hash-verified

140}
141
142function removeWorker(worker) {
143 assert(worker);
144 delete cluster.workers[worker.id];
145
146 if (ObjectKeys(cluster.workers).length === 0) {
147 assert(handles.size === 0, 'Resource leak detected.');
148 intercom.emit('disconnect');
149 }
150}
151
152function removeHandlesForWorker(worker) {
153 assert(worker);

Callers 1

primary.jsFile · 0.85

Calls 2

assertFunction · 0.50
emitMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…