MCPcopy Create free account
hub / github.com/vercel/vercel / killAll

Function killAll

packages/ruby/src/start-dev-server.ts:64–86  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62 cleanupHandlersInstalled = true;
63
64 const killAll = () => {
65 for (const [key, info] of PERSISTENT_SERVERS.entries()) {
66 try {
67 process.kill(info.pid, 'SIGTERM');
68 } catch (err: any) {
69 debug(`Error sending SIGTERM to ${info.pid}: ${err}`);
70 }
71 try {
72 process.kill(info.pid, 'SIGKILL');
73 } catch (err: any) {
74 debug(`Error sending SIGKILL to ${info.pid}: ${err}`);
75 }
76 PERSISTENT_SERVERS.delete(key);
77 }
78 if (restoreWarnings) {
79 try {
80 restoreWarnings();
81 } catch (err: any) {
82 debug(`Error restoring warnings: ${err}`);
83 }
84 restoreWarnings = null;
85 }
86 };
87
88 // Do not exit on signals, so other interruption handlers
89 // can perform their cleanup routine.

Callers 1

Calls 3

debugFunction · 0.90
killMethod · 0.80
deleteMethod · 0.45

Tested by

no test coverage detected