Professional OPC
Development Tools

logos

DataChange event firing every 5 seconds for disconnected devices/servers

More
02 Aug 2019 14:29 - 02 Aug 2019 14:30 #7603 by support
Hello.

Ad 1. This is a sign of the fact that the component is trying to reconnect, and it is by design. As long as the connection attempts keep failing, you will keep receiving these events. This way, if you are observing the notification for any particular, the last notification you received reflects the current status. If we had suppressed the notifications after first failure, observing the notifications wouldn't tell you *when* the last reconnect failed - you would only know about the first disconnect. And the precise reason/status can also change - while still being in failure. The fact that there are two of these is the only detail that was not designed into the software intentionally, but instead came out of the implementation- it would be better if there was just one, I agree, and we know about it (the second one you listed is the one that has the usual information in it, which can bring insight into the problem; the first one is kind of unnecessary). Maybe in future this will improve.

By default, the component tries to reconnect very frequently - every 10 seconds (in the end it can be somewhat more, but this is the main number). You can change it using this property: opclabs.doc-that.com/files/onlinedocs/QuickOpc/Latest/User's...onParameters~RetrialDelay.html .

Ad 2. This is manifestation of the same process - the reconnection attempts. You should be seeing state changes from Disconnected to Connecting - but then, back to Disconnected when it fails. And finally from Connecting to Connected, when the device is plugged in. That's how it should work. The frequency depends on the same setting as described above.

Best regards
Last edit: 02 Aug 2019 14:30 by support.

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

More
01 Aug 2019 17:52 #7595 by sjscheider
If I unplug or turn off a device, 2 things are happening that I'd like to get more information about.
  1. It appears that the data change event is firing for all subscriptions every 5 seconds. What is the purpose of this event firing since there is not any data changes to report? What actions do you recommend performing in this scenario? We are capturing this an an error condition and we are getting way too many errors when multiple devices are disconnected unexpectedly. (Example, the network cable is unplugged from a switch.) Should we simply ignore all events. What would be the recommended way to detect the event? We currently see 2 different messages.
    StatusInfo: Unknown
    ErrorCode: -1
    ErrorMessageBrief: OPC-UA client session is not available when connecting the client subscription.
    StatusInfo: Unknown
    ErrorCode: -2138439680
    ErrorMessageBrief: OPC-UA service result - Error establishing a connection: BadNotConnected = BadNotConnected.
    Are there any setting to make this event occur less often? What are the ramifications of changing these settings?
  2. In the ServerConditionChanged event handler, we the Connections ConnectionState event firing every 15 seconds. What settings controller this frequency? What are the ramifications of changing these settings?

Thanks for all of your assistance.

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

Moderators: support
Time to create page: 0.169 seconds

      

 Recommend this on Google