src/vs/workbench/services/workingCopy/electron-sandbox/workingCopyHistoryService.ts/NativeWorkingCopyHistoryService/onWillShutdown
class NativeWorkingCopyHistoryService:	private onWillShutdown(e: WillShutdownEvent): void {

		// Prolong shutdown for orderly model shutdown
		e.join((async () => {
			const limiter = new Limiter(MAX_PARALLEL_HISTORY_IO_OPS);
			const promises = [];

			const models = Array.from(this.models.values());
			for (const model of models) {
				promises.push(limiter.queue(async () => {
					if (e.token.isCancellationRequested) {
						return;
					}

					try {
						await model.store(e.token);
					} catch (error) {
						this.logService.trace(error);
					}
				}));
			}

			await Promise.all(promises);
		})(), 'join.workingCopyHistory');
	}