OPC UA Node error

Hi,

We have a Module that has been running on our projects for few years but we have noticed that since we updated ignition to 8.1 we receive this error.

Caused by: java.lang.ClassNotFoundException: org.eclipse.milo.opcua.sdk.server.api.nodes.Node

Has something changed to kick up this error?

Yes. It may be as simple as recompiling your module with v8.1 dependencies. See this discussion:

3 Likes

With the SDK change, is that this part of the code?

<properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <ignition-sdk-version>8.1.0</ignition-sdk-version>
</properties>

Presumably. I don’t use maven, so my build environment is totally different.

I’ve updated the SDK to 8.1.0 but i’m still getting the same error.

java.lang.NoClassDefFoundError: org/eclipse/milo/opcua/sdk/server/api/nodes/Node

at com.hanleyenergy.drivers.modbus.configuration.ModbusTcpDriverType.createDriver(ModbusTcpDriverType.java:61)

at com.inductiveautomation.ignition.gateway.opcua.server.DriverAdapter.startup(DriverAdapter.kt:128)

at com.inductiveautomation.ignition.gateway.opcua.server.DeviceManager$DeviceAddressSpace.startup(DeviceManager.kt:331)

at com.inductiveautomation.ignition.gateway.opcua.server.DeviceManager.createAndStartupDevice(DeviceManager.kt:194)

at com.inductiveautomation.ignition.gateway.opcua.server.DeviceManager.access$createAndStartupDevice(DeviceManager.kt:43)

at com.inductiveautomation.ignition.gateway.opcua.server.DeviceManager$DeviceSettingsRecordListener$recordUpdated$1.invokeSuspend(DeviceManager.kt:286)

Did you recompile your module? Something isn’t right here because you still have code that references a package that no longer exists.

I recompiled and resigned it after i made the changes

<properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <ignition-sdk-version>8.1.0</ignition-sdk-version>
</properties>

This is the correct piece to change ?

It’s a great candidate, but I couldn’t tell you anything definitively without seeing your entire project.

You may also simply have old dependencies being added inside your module that gets built as a result of not cleaning first (mvn clean).

This lead me to the real issue.
The AccessLevel class has been changed with the recent milo update.
They changed the ‘getMask’ function