You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "col-panic (via GitHub)" <gi...@apache.org> on 2026/05/26 11:49:25 UTC
[I] Milo - provide native support to split into client / server part [camel-quarkus]
col-panic opened a new issue, #8698:
URL: https://github.com/apache/camel-quarkus/issues/8698
### Describe the feature here
I added
```
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-milo</artifactId>
<exclusions>
<exclusion>
<artifactId>milo-sdk-server</artifactId>
<groupId>org.eclipse.milo</groupId>
</exclusion>
</exclusions>
</dependency>
```
like this, as I only need the client part for a native build, and the server just bloats everything. But during native compile I see
```
[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:3.34.7:build (default) on project fcs: Failed to build quarkus application: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
[ERROR] [error]: Build step org.apache.camel.quarkus.component.milo.deployment.MiloProcessor#runtimeInitializedClasses threw an exception: java.lang.NoClassDefFoundError: org/eclipse/milo/opcua/sdk/server/OpcUaServer
[ERROR] at org.apache.camel.quarkus.component.milo.deployment.MiloProcessor.runtimeInitializedClasses(MiloProcessor.java:41)
[ERROR] at java.base/java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:735)
[ERROR] at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:898)
[ERROR] at io.quarkus.builder.BuildContext.run(BuildContext.java:242)
[ERROR] at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR] at org.jboss.threads.EnhancedQueueExecutor$Task.doRunWith(EnhancedQueueExecutor.java:2651)
[ERROR] at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2630)
[ERROR] at org.jboss.threads.EnhancedQueueExecutor.runThreadBody(EnhancedQueueExecutor.java:1694)
[ERROR] at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1589)
[ERROR] at java.base/java.lang.Thread.run(Thread.java:1474)
[ERROR] at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[ERROR] Caused by: java.lang.ClassNotFoundException: org.eclipse.milo.opcua.sdk.server.OpcUaServer
[ERROR] at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:42)
[ERROR] at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:225)
[ERROR] at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:210)
[ERROR] at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:205)
[ERROR] at io.quarkus.bootstrap.classloading.QuarkusClassLoader.loadClass(QuarkusClassLoader.java:578)
[ERROR] at io.quarkus.bootstrap.classloading.QuarkusClassLoader.loadClass(QuarkusClassLoader.java:525)
[ERROR] ... 11 more
[ERROR] -> [Help 1]
```
Not sure why server is needed - I don't do any server references, and as documented in https://github.com/quarkusio/quarkus/issues/54459 I reverted to using only the client library which works - if not doing native!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Milo - provide native support to split into client / server part [camel-quarkus]
Posted by "jamesnetherton (via GitHub)" <gi...@apache.org>.
jamesnetherton commented on issue #8698:
URL: https://github.com/apache/camel-quarkus/issues/8698#issuecomment-4590513341
That's somewhat expected. You typically can't add arbitrary dependency exclusions and have the native app compile successfully. The compiler will find code paths to classes that have been excluded. `OpcUaServer` is required by the `camel-milo` consumer, hence the error.
You might be able to work around it by adding this to application.properties:
```
quarkus.native.additional-build-args=--allow-incomplete-classpath
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Milo - provide native support to split into client / server part [camel-quarkus]
Posted by "jamesnetherton (via GitHub)" <gi...@apache.org>.
jamesnetherton closed issue #8698: Milo - provide native support to split into client / server part
URL: https://github.com/apache/camel-quarkus/issues/8698
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Milo - provide native support to split into client / server part [camel-quarkus]
Posted by "col-panic (via GitHub)" <gi...@apache.org>.
col-panic commented on issue #8698:
URL: https://github.com/apache/camel-quarkus/issues/8698#issuecomment-4590581405
@jamesnetherton I managed to find a way, I just took the source of the camel-quarkus-milo plug and it manually by only adding:
```
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-milo</artifactId>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-netty</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.milo</groupId>
<artifactId>milo-sdk-client</artifactId>
<version>${milo.version}</version>
</dependency>
```
and setting
```
quarkus.native.additional-build-args=--initialize-at-run-time=com.digitalpetri.netty.fsm.ChannelFsmConfigBuilder$SharedExecutor\\,com.digitalpetri.netty.fsm.ChannelFsmConfigBuilder$SharedScheduler\\,\
org.eclipse.milo.opcua.stack.core.util.BufferUtil\\,org.eclipse.milo.opcua.sdk.client.OpcUaClient\\,org.eclipse.milo.opcua.stack.core.util.NonceUtil
``` in `application.properties`
The native build is now much smaller :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Milo - provide native support to split into client / server part [camel-quarkus]
Posted by "col-panic (via GitHub)" <gi...@apache.org>.
col-panic commented on issue #8698:
URL: https://github.com/apache/camel-quarkus/issues/8698#issuecomment-4590955446
@jamesnetherton yes - but I used the approach I learned through the source of `camel-quarkus-milo`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Milo - provide native support to split into client / server part [camel-quarkus]
Posted by "jamesnetherton (via GitHub)" <gi...@apache.org>.
jamesnetherton commented on issue #8698:
URL: https://github.com/apache/camel-quarkus/issues/8698#issuecomment-4590945255
@col-panic To clarify - are you using the Milo client standalone? i.e. no Camel usage?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Milo - provide native support to split into client / server part [camel-quarkus]
Posted by "jamesnetherton (via GitHub)" <gi...@apache.org>.
jamesnetherton commented on issue #8698:
URL: https://github.com/apache/camel-quarkus/issues/8698#issuecomment-4591032521
Ok - then I'll likely close this, since there's a workaround.
From a Camel application POV, the Milo extension always provides the consumer (server) & producer (client) parts.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org