lorenzodonini / ocpp-go

Open Charge Point Protocol implementation in Go
MIT License
277 stars 126 forks source link

Configurable session timeout #278

Open Mayuri-Mense opened 5 months ago

Mayuri-Mense commented 5 months ago

Hi, I noticed that the write wait is 10 seconds and the ping wait is 60 seconds by default in the servertimeout configuration.

My question is: Can we set the ping wait for each client individually? like per session ?

Currently, charger's heartbeat interval is set by the interval specified in BootConfiguration.conf. By using server code, we can ensure that heartbeat will always be less than ping wait; however, if this is added as a configuration key that the user can change, the server should also handle the situation in which the user's specified heartbeat exceeds ping wait.

Please help to solve the problem

lorenzodonini commented 3 months ago

This is currently not supported and it's a tricky requirement. How would you configure different heartbeats for different clients though?

I don't know when I'll have the time to work on this, but I'm happy to take contributions!