23:56, EET
December 1, 2016
Hello,
We are developing a client, and the browse is slow. Specifically, we come across a node with a fairly large number of leaves, and it takes a very long time to get those nodes from the address space. Its really this block of code that seems to be taking a long time with this:
// add those references to the nodes to be visited
for(ReferenceDescription reference : references) {
UaNode referenceNode = addressSpace.getNode(reference.getNodeId());
nodesToVisit.add(referenceNode.getNodeId());
}
Is getting a node in this manner inefficient? Is there a better way to ensure we browse the entire address space, but more quickly.
We are browsing a Kepware Server if that is relevant at all
9:53, EET
April 17, 2013
Hello,
The AddressSpace.getNode method initializes all kinds of information about the UaNode in question: it reads common attributes of the node and in addition to that, attributes that are specific to the NodeClass in question. The method also browses the properties of the node and initializes the Properties into the node object. The reasoning behind this implementation is that in common cases this should caching mechanism should be efficient.
As a start, please see this forum discussion about similar subject: http://forum.prosysopc.com/for…..tesnodeid/
15:26, EET
December 1, 2016
16:09, EET
April 17, 2013
16:27, EET
December 1, 2016
Oh I see, that definitely cleared a few things up and helps that part of the code run more quickly. I am still getting a slow browse however, and it is due to still calling addressSpace.getNode(nodeId) in order to get certain items from the node itself. Are there better methods to get the:
– Supported attributes of the node
– Browse name
– Canonical name
Please let me know if you have some methods for extracting this information from the address space, rather than the node itself.
16:56, EET
April 17, 2013
Hi,
All these things can be read from the node with the basic read calls.
– Attributes are NodeClass specific, so you can find out what attributes are supported by reading the NodeClass.
– Every node in the address space has a BrowseName attribute.
– I guess you mean DisplayName attribute with ‘Canonical name’. This attribute is also available in all NodeClasses.
Looking at the Javadoc documentation of UaClient.readXxx methods will probably get you started nicely. You can read the mentioned attributes for example with
However, I wouldn’t call this ‘better’ than using the addressSpace.getNode. This is more optimized but on the other hand you must know more about the OPC UA specification yourself. But if you have a situation where you need to optimize the browse and read calls, then using these simpler versions may help.
17:24, EET
December 1, 2016
16:55, EET
April 17, 2013
According to my understanding, we have no reason to believe that Kepware servers would somehow offer poor performance. That being said, of course any single application could be having some performance issues.
Are you accessing the same server via UaGateway? Or are you browsing some other server via the UaGateway? If you are browsing for the exactly same data and from UaGateway it’s considerably faster, then this does sound strange.
Have you tried making the same kind of browsing with different general purpose OPC UA Clients? Is the browsing slow also with other client applications?
Most Users Ever Online: 1919
Currently Online:
71 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Heikki Tahvanainen: 402
hbrackel: 144
rocket science: 88
pramanj: 86
Francesco Zambon: 83
Ibrahim: 78
Sabari: 62
kapsl: 57
gjevremovic: 49
Xavier: 43
Member Stats:
Guest Posters: 0
Members: 730
Moderators: 7
Admins: 1
Forum Stats:
Groups: 3
Forums: 15
Topics: 1529
Posts: 6471
Newest Members:
HypromeImpupe, toneylapham544, rondawolinski7, Marypof5711, roycedelargie91, kourtneyquisenbe, ellis87832073466, zkxwilliemae, gabriellabachus, DeakinModerators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1032, Jimmy Ni: 26, Matti Siponen: 349, Lusetti: 0
Administrators: admin: 1