1 import type { ListenOptions
} from
'node:net';
3 import type { WorkerChoiceStrategy
} from
'poolifier';
5 import type { StorageType
} from
'./Storage';
6 import type { ApplicationProtocol
, AuthenticationType
} from
'./UIProtocol';
7 import type { WorkerProcessType
} from
'../worker';
9 type ServerOptions
= ListenOptions
;
11 export enum SupervisionUrlDistribution
{
12 ROUND_ROBIN
= 'round-robin',
14 CHARGING_STATION_AFFINITY
= 'charging-station-affinity',
17 export type StationTemplateUrl
= {
19 numberOfStations
: number;
22 export type LogConfiguration
= {
26 statisticsInterval
?: number;
31 maxFiles
?: string | number;
32 maxSize
?: string | number;
35 export type UIServerConfiguration
= {
37 type?: ApplicationProtocol
;
38 options
?: ServerOptions
;
41 type: AuthenticationType
;
47 export type StorageConfiguration
= {
53 export type WorkerConfiguration
= {
54 processType
?: WorkerProcessType
;
56 elementsPerWorker
?: number | 'auto';
57 elementStartDelay
?: number;
60 /** @deprecated Not publicly exposed to end users. */
61 poolStrategy
?: WorkerChoiceStrategy
;
64 export type ConfigurationData
= {
65 supervisionUrls
?: string | string[];
66 supervisionUrlDistribution
?: SupervisionUrlDistribution
;
67 stationTemplateUrls
: StationTemplateUrl
[];
68 log
?: LogConfiguration
;
69 worker
?: WorkerConfiguration
;
70 uiServer
?: UIServerConfiguration
;
71 performanceStorage
?: StorageConfiguration
;
72 autoReconnectMaxRetries
?: number;
73 /** @deprecated Moved to worker configuration section. */
74 workerProcess
?: WorkerProcessType
;
75 /** @deprecated Moved to worker configuration section. */
76 workerStartDelay
?: number;
77 /** @deprecated Moved to worker configuration section. */
78 elementStartDelay
?: number;
79 /** @deprecated Moved to worker configuration section. */
80 workerPoolMinSize
?: number;
81 /** @deprecated Moved to worker configuration section. */
82 workerPoolMaxSize
?: number;
83 /** @deprecated Moved to worker configuration section. */
84 workerPoolStrategy
?: WorkerChoiceStrategy
;
85 /** @deprecated Moved to worker configuration section. */
86 chargingStationsPerWorker
?: number;
87 /** @deprecated Moved to log configuration section. */
88 logStatisticsInterval
?: number;
89 /** @deprecated Moved to log configuration section. */
91 /** @deprecated Moved to log configuration section. */
93 /** @deprecated Moved to log configuration section. */
95 /** @deprecated Moved to log configuration section. */
97 /** @deprecated Moved to log configuration section. */
99 /** @deprecated Moved to log configuration section. */
100 logMaxFiles
?: number | string;
101 /** @deprecated Moved to log configuration section. */
102 logMaxSize
?: number | string;
103 /** @deprecated Moved to log configuration section. */
105 /** @deprecated Moved to log configuration section. */
106 logErrorFile
?: string;