Consistent naming for CS template enums
[e-mobility-charging-stations-simulator.git] / src / utils / Constants.ts
index 31a673281c8b9a43a2d37b405b611ce0a2c04588..350170aacd1e3ca94f8425f31aecc35b14dee9c1 100644 (file)
@@ -1,4 +1,6 @@
-import { AvailabilityStatus, ChargingProfileStatus, ClearChargingProfileStatus, ConfigurationStatus, DefaultStatus, UnlockStatus } from '../types/ocpp/1.6/RequestResponses';
+import { AvailabilityStatus, ChargingProfileStatus, ClearChargingProfileStatus, ConfigurationStatus, DefaultStatus, UnlockStatus } from '../types/ocpp/Responses';
+
+import { MeterValueMeasurand } from '../types/ocpp/MeterValues';
 
 export default class Constants {
   static readonly ENTITY_CHARGING_STATION = 'ChargingStation';
@@ -29,8 +31,18 @@ export default class Constants {
   static readonly CHARGING_STATION_ATG_WAIT_TIME = 2000; // Ms
   static readonly CHARGING_STATION_ATG_INITIALIZATION_TIME = 1000; // Ms
 
-  static readonly TRANSACTION_DEFAULT_TAGID = '00000000';
+  static readonly TRANSACTION_DEFAULT_IDTAG = '00000000';
 
-  static readonly START_WORKER_DELAY = 500;
+  static readonly WORKER_START_DELAY = 500;
   static readonly WORKER_POOL_MAX_INACTIVE_TIME = 60000;
+  static readonly DEFAULT_WORKER_POOL_MIN_SIZE = 4;
+  static readonly DEFAULT_WORKER_POOL_MAX_SIZE = 16;
+  static readonly DEFAULT_CHARGING_STATIONS_PER_WORKER = 1;
+
+  static readonly DEFAULT_CONNECTION_TIMEOUT = 30;
+
+  static readonly SUPPORTED_MEASURANDS = Object.freeze([MeterValueMeasurand.STATE_OF_CHARGE, MeterValueMeasurand.VOLTAGE,
+    MeterValueMeasurand.POWER_ACTIVE_IMPORT, MeterValueMeasurand.CURRENT_IMPORT, MeterValueMeasurand.ENERGY_ACTIVE_IMPORT_REGISTER]);
+
+  static readonly DEFAULT_FLUCTUATION_PERCENT = 5;
 }