X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Ftypes%2FConfigurationData.ts;h=d1948921660b0da42774c813686405c2baf4d74c;hb=6a4032b5d8f3cbaa18d3beddcdfe9d335c1cba90;hp=95d30bdc8024fbef1cd21e1c55e91212ca4464d1;hpb=a60809049f58eb001d868717a1dda9ac129f8a53;p=e-mobility-charging-stations-simulator.git diff --git a/src/types/ConfigurationData.ts b/src/types/ConfigurationData.ts index 95d30bdc..d1948921 100644 --- a/src/types/ConfigurationData.ts +++ b/src/types/ConfigurationData.ts @@ -1,4 +1,5 @@ import type { ListenOptions } from 'node:net'; +import type { ResourceLimits } from 'node:worker_threads'; import type { WorkerChoiceStrategy } from 'poolifier'; @@ -63,15 +64,16 @@ export interface StorageConfiguration { uri?: string; } +export type ElementsPerWorkerType = number | 'auto' | 'all'; + export interface WorkerConfiguration { processType?: WorkerProcessType; startDelay?: number; - elementsPerWorker?: number | 'auto'; + elementsPerWorker?: ElementsPerWorkerType; elementStartDelay?: number; poolMinSize?: number; poolMaxSize?: number; - /** @deprecated Not publicly exposed to end users. */ - poolStrategy?: WorkerChoiceStrategy; + resourceLimits?: ResourceLimits; } export interface ConfigurationData { @@ -82,6 +84,7 @@ export interface ConfigurationData { worker?: WorkerConfiguration; uiServer?: UIServerConfiguration; performanceStorage?: StorageConfiguration; + /** @deprecated Moved to charging station template */ autoReconnectMaxRetries?: number; /** @deprecated Moved to worker configuration section. */ workerProcess?: WorkerProcessType;