Log URL of the charger connecting to the backend
MODIFY
src/server/ocpp/json/WSConnection.ts
src/server/ocpp/json/WSConnection.ts
@@ -42,7 +42,12 @@ export default abstract class WSConnection {
this.req = req;
this.initialized = false;
this.wsServer = wsServer;
-
+ Logging.logDebug({
+ tenantID: Constants.DEFAULT_TENANT,
+ action: ServerAction.WS_JSON_CONNECTION_OPENED,
+ module: MODULE_NAME, method: 'constructor',
+ message: `Charging Station attemps to connect with URL: '${req.url}'`,
+ });
// Default
this.tenantIsValid = false;
// Check URL: remove starting and trailing '/'
@@ -74,6 +79,12 @@ export default abstract class WSConnection {
message: `The URL '${req.url}' is invalid (/OCPPxx/TENANT_ID/CHARGEBOX_ID)`
});
}
+ Logging.logDebug({
+ tenantID: this.tenantID,
+ action: ServerAction.WS_JSON_CONNECTION_OPENED,
+ module: MODULE_NAME, method: 'constructor',
+ message: `Charging Station attemps to connect with URL: '${req.url}'`,
+ });
if (!Utils.isChargingStationIDValid(this.chargingStationID)) {
const backendError = new BackendError({
source: this.chargingStationID,

Log URL of the charger connecting to the backend