Professional OPC
Development Tools


The OPC-UA subscription publishing has stopped.

29 Aug 2014 11:39 #2196 by support
Yes, it is coming from a form of keep-alive. The keep-alive mechanism is required by the OPC-UA specification and cannot be completely switched off.

Some things to check:
  1. Isn't it a reflection of a true problem, such as network connectivity losses? (Question: are the server and the client on the same computer?)
  2. Isn't the use debugging the client or server application, or causing the process to pause by other means?
  3. What is the CPU usage of the client and server application, and of the computer overall (both server and client computers)? Periods of very high CPU usage can cause the keep-alives to fail.

A parameter that influences the keep-alive is:
  • static EasyUAClient.AdaptableParameters.Session.KeepAliveInterval (in the default state, with EasyUAClient.Isolated == false), or
  • EasyUAClient.IsolatedParameters.Session.KeepAliveInterval (if you explicitly set EasyUAClient.Isolated = true).

Here is from its documentation (KeepAliveInterval):

Summary: How frequently the server is pinged to see if communication is still working (in milliseconds).
Value: Frequency in milliseconds, or System.Threading.Timeout.Infinite to disable the keep alive monitoring.
Remarks: This interval controls (but does not directly mean) how much time elapses before a communication error is detected.
This parameter is not interpreted by the component; it is simply passed down to the OPC UA Stack for processing.
Subscription Service Set: "When there are no Notifications to send within the keep-alive time interval, the Server sends a keep-alive Message … . If a Client fails to receive a Message after the keep-alive interval has expired, or if it determines that it has missed a Message, it can request the Server to resend one or more Messages."

Note that the "disabling" (mentioned in the doc) is just an attempt by the client, but a compliant server will turn it down by modifying to a value it feels comfortable with.

Debugging this situation (by means of usual debugger with breakpoints etc.) is practically
impossible, because the debugging itself is going to cause more keep-alive failures: Please read this thread for a good overview of what happens then: . Also, there is a change in the parameter that needs to be changed: it is KeepAliveIntervaleDebug under the debugger. In some scenarios (depends on the endpoint parameters, and security requirements), the OPC Foundation's compliance test tool can be used to view the communication between the client or the server (only for OPC Foundation members); and, there is a Wireshark plugin as well, however using any of these is for experienced only.

Best regards
The following user(s) said Thank You: g.aino

Please Log in or Create an account to join the conversation.

29 Aug 2014 07:42 #2195 by
Hi, One of my clients gets this exception about every 5 - 10 minutes.

OpcLabs.EasyOpc.UA.UAClientEngineException: The OPC-UA subscription publishing has stopped.

I understand that this is a form of keep alive that isn't revived in time? Is there a way for me to debug this? Is there anything I might be doing that stops the keep alive from being sent/revived. Is there any setting I can set to increase the keep alive interval?

Bard Hustveit

Please Log in or Create an account to join the conversation.

Moderators: support
Time to create page: 0.163 seconds


 Recommend this on Google