Hello everyone,
I have a (hopefully) small question.
Is there a way to monitor a connection on an custom OPCUA-Server? Similar to a Keep-Alive that is running in the client.
The background is following:
I have a custom OPCUA Server that I can sometimes not connect to. It happens only after a while of successfull connections of a client. Sometimes after hours, sometimes after days. In that case a restart of the client does not help. It still does not connect. Only after a restart of the OPCUA-Server a connection can be established. I am working on finding the problem.
But nonetheless it would be nice to have a mechanism, where I can react to the lost connection in in realtime within the server and for example send an alert to someone, write a log etc.
So far I could only find "SessionManager.SessionClosing"-Event. But depending on the Sessiontimeout it would take a long time to notice the lost connection. Too long.
Any hint would be appreciated.
Thx in advance,
Sven
Monitoring a connection on a custom OPCUA Server
Moderator: uasdknet
-
- Jr. Member
- Posts: 1
- Joined: 16 Oct 2020, 07:59
- Support Team
- Hero Member
- Posts: 3064
- Joined: 18 Mar 2011, 15:09
Re: Monitoring a connection on a custom OPCUA Server
Hello,
The SessionClosing EventHandler of the SessionManager is the only provided way a server application can get informed about a disconnected client.
You can specify the MaxSessionTimeout in the SessionSettings to enforce a faster closing of the sessions.
The SessionClosing EventHandler of the SessionManager is the only provided way a server application can get informed about a disconnected client.
You can specify the MaxSessionTimeout in the SessionSettings to enforce a faster closing of the sessions.
Best regards
Unified Automation Support Team
Unified Automation Support Team