src/vs/workbench/contrib/debug/browser/rawDebugSession.ts/RawDebugSession/shutdown
class RawDebugSession:	private async shutdown(error?: Error, restart = false, terminateDebuggee: boolean | undefined = undefined, suspendDebuggee: boolean | undefined = undefined): Promise<any> {
		if (!this.inShutdown) {
			this.inShutdown = true;
			if (this.debugAdapter) {
				try {
					const args: DebugProtocol.DisconnectArguments = { restart };
					if (typeof terminateDebuggee === 'boolean') {
						args.terminateDebuggee = terminateDebuggee;
					}

					if (typeof suspendDebuggee === 'boolean') {
						args.suspendDebuggee = suspendDebuggee;
					}

					this.send('disconnect', args, undefined, 2000);
				} catch (e) {
					// Catch the potential 'disconnect' error - no need to show it to the user since the adapter is shutting down
				} finally {
					this.stopAdapter(error);
				}
			} else {
				return this.stopAdapter(error);
			}
		}
	}