The ServerCapabilities->ModellingRules object should not be empty because the stack uses modellingrules. #2524
Labels
compliance
An issue was found which is not compliant with the OPC UA specification.
need triage
server
Type of issue
Current Behavior
The stack currently does not populate the servercapabilities->modellingrules folder with the rules that are used by the stack in the populated datatypes addresspace. This means that all servers need to add these modellingrules manually to be compliant and it places the reference server in a state where it is not compliant.
Additionally, adding modellingrules is difficult because it requires adding nodes that are defined by Opc.Ua.Nodeset.xml but not exposed in the code.
Expected Behavior
The folder should contain any modellingrules (and their namingrules) that the stack utilizes. At least these modellingrules are used by the stack: Mandatory, Optional, OptionalPlaceholder, and ExposesItsArray. It's possible ManditoryPlaceholder is used as well, but I was unable to find its use. To see these, browse the references of many of the nodes in the Types folder of the addressspace and look for the "HasModellingRule" reference type.
A nice-to-have would be the ability to add/override modellingrules when a server wishes its own ruleset. A server should define all rules used, so the stack may not necessarily use all the rules that a server would ultimately use.
Steps To Reproduce
Environment
Anything else?
The requirement for including all used modellingrules is described in the spec here:
"ModellingRules is an entry point to browse to all ModellingRules supported by the Server. All ModellingRules supported by the Server should be able to be browsed starting from this Object."
We believe following the implementation used by the AggregateManager is ideal as a precedent. This solution solves a few problems:
The text was updated successfully, but these errors were encountered: