Closed samarasdelta closed 7 months ago
The answer is YES, the problem is that I'm trying to switch from one connection to another and I'm keep getting errors like this one bellow:
at new URL (internal/url.js:319:5)
at initAsClient (/home/ubuntu/ev-server/node_modules/ws/lib/websocket.js:502:17)
at new WebSocket (/home/ubuntu/ev-server/node_modules/ws/lib/websocket.js:71:7)
at WSClient.open (/home/ubuntu/ev-server/dist/webpack:/src/client/websocket/WSClient.ts:49:15)
at new WSClient (/home/ubuntu/ev-server/dist/webpack:/src/client/websocket/WSClient.ts:45:10)
at Promise (/home/ubuntu/ev-server/dist/webpack:/src/client/ocpp/json/JsonRestChargingStationClient.ts:121:27)
at Promise._execute (/home/ubuntu/ev-server/node_modules/bluebird/js/release/debuggability.js:384:9)
at Promise._resolveFromExecutor (/home/ubuntu/ev-server/node_modules/bluebird/js/release/promise.js:518:18)
at new Promise (/home/ubuntu/ev-server/node_modules/bluebird/js/release/promise.js:103:10)
at JsonRestChargingStationClient.openConnection (/home/ubuntu/ev-server/dist/webpack:/src/client/ocpp/json/JsonRestChargingStationClient.ts:102:18) input: 'null/REST/60af3c96490af47d011f5bd7/CS-SIEMENS>
is there any possible solution to this?
If anyone is interested, I managed to make wss and ws protocols existing with nginx simultaneously by redirecting all ws connections to the wss. Pretty simple solution, although it seems very stable. I've been a testing a while now and everything seems to be ok. If anyone wants any help feel free to contact!
Does anyone know if I can use ws and wss at the same time?
Server is configured and running on https.
Μy config.json file on the server side looks like this:
So far, I've tested it with two simulators (one for ws protocol and one for wss) and haven't been able to reach a solution.
Both simulators can connect to the server, but only one of them can start a charging session.
Part of my etc/hosts file (windows) bellow:
Any reply would be greatly appreciated :)
PS: I'm using version 2.4.66 (ev-server & ev-dashboard)