Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
import { dirname, extname, join } from 'node:path';
import { exit } from 'node:process';
import { fileURLToPath } from 'node:url';
import { dirname, extname, join } from 'node:path';
import { exit } from 'node:process';
import { fileURLToPath } from 'node:url';
-import { isMainThread } from 'node:worker_threads';
import chalk from 'chalk';
import { availableParallelism } from 'poolifier';
import chalk from 'chalk';
import { availableParallelism } from 'poolifier';
}
public async start(): Promise<void> {
}
public async start(): Promise<void> {
- if (!isMainThread) {
- throw new BaseError('Cannot start charging stations simulator from worker thread');
- }
if (this.started === false) {
if (this.starting === false) {
this.starting = true;
if (this.started === false) {
if (this.starting === false) {
this.starting = true;