[
https://issues.apache.org/jira/browse/CAMEL-23600?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Work on CAMEL-23600 started by Andrea Cosentino.
------------------------------------------------
> camel-milo: expose the underlying Eclipse Milo OpcUaClient for custom OPC UA
> DataType handling
> ----------------------------------------------------------------------------------------------
>
> Key: CAMEL-23600
> URL: https://issues.apache.org/jira/browse/CAMEL-23600
> Project: Camel
> Issue Type: Improvement
> Components: camel-milo
> Reporter: Andrea Cosentino
> Assignee: Andrea Cosentino
> Priority: Minor
> Fix For: 4.21.0
>
>
> The camel-milo OPC UA client reads and writes built-in OPC UA data types
> correctly, but values of custom (server-defined) data types are returned as
> ExtensionObject instances. These cannot be decoded (nor encoded, for writes)
> without access to the underlying Eclipse Milo OpcUaClient encoding contexts
> (getStaticEncodingContext() / getDynamicEncodingContext()).
> At present the OpcUaClient is held privately inside
> SubscriptionManager.Connected and is not reachable from outside the
> component, so users have no way to obtain the encoding contexts.
> This improvement exposes the active OpcUaClient via a new
> MiloClientConnection.getOpcUaClient() accessor (delegating through
> SubscriptionManager). Users can then obtain the connection from the
> MiloClientEndpoint, retrieve the milo client and its encoding contexts, and
> perform custom DataType encode/decode themselves
> (ExtensionObject.encode/decode).
> The accessor is purely additive; no existing public API changes. It returns
> null while the connection is not established (the connection is
> lazy/asynchronous and is re-created on reconnect), and the client lifecycle
> remains owned by Camel.
> Reported on the Apache Camel user mailing list.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)