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;
57 elementStartDelay
?: number;
60 poolStrategy
?: WorkerChoiceStrategy
;
63 export type ConfigurationData
= {
64 supervisionUrls
?: string | string[];
65 supervisionUrlDistribution
?: SupervisionUrlDistribution
;
66 stationTemplateUrls
: StationTemplateUrl
[];
67 log
?: LogConfiguration
;
68 worker
?: WorkerConfiguration
;
69 uiServer
?: UIServerConfiguration
;
70 performanceStorage
?: StorageConfiguration
;
71 autoReconnectMaxRetries
?: number;
72 /** @deprecated Moved to worker configuration section. */
73 workerProcess
?: WorkerProcessType
;
74 /** @deprecated Moved to worker configuration section. */
75 workerStartDelay
?: number;
76 /** @deprecated Moved to worker configuration section. */
77 elementStartDelay
?: number;
78 /** @deprecated Moved to worker configuration section. */
79 workerPoolMinSize
?: number;
80 /** @deprecated Moved to worker configuration section. */
81 workerPoolMaxSize
?: number;
82 /** @deprecated Moved to worker configuration section. */
83 workerPoolStrategy
?: WorkerChoiceStrategy
;
84 /** @deprecated Moved to worker configuration section. */
85 chargingStationsPerWorker
?: number;
86 /** @deprecated Moved to log configuration section. */
87 logStatisticsInterval
?: number;
88 /** @deprecated Moved to log configuration section. */
90 /** @deprecated Moved to log configuration section. */
92 /** @deprecated Moved to log configuration section. */
94 /** @deprecated Moved to log configuration section. */
96 /** @deprecated Moved to log configuration section. */
98 /** @deprecated Moved to log configuration section. */
99 logMaxFiles
?: number | string;
100 /** @deprecated Moved to log configuration section. */
101 logMaxSize
?: number | string;
102 /** @deprecated Moved to log configuration section. */
104 /** @deprecated Moved to log configuration section. */
105 logErrorFile
?: string;