smongiar opened a new pull request, #22835:
URL: https://github.com/apache/camel/pull/22835

   ## Summary
   
   - Add explicit `setHost("127.0.0.1")` call when launching hawtio-embedded, 
instead of relying on its default `"localhost"`
   - Add `--host` CLI option to `camel hawtio` command for user-configurable 
binding
   - Update browser URL to use the configured host instead of hardcoded 
`localhost`
   
   ## Problem
   
   On s390x and ppc64le architectures, `camel hawtio` fails with a 
`ConnectException` caused by `ClosedChannelException`. The root cause is that 
hawtio-embedded's default host `"localhost"` is resolved via 
`InetAddress.getByName("localhost")`, which may return `::1` (IPv6 loopback) on 
these systems. If IPv6 is disabled or NIO sockets behave differently, Jetty 
binds to an unreachable address.
   
   The `camel jolokia` command (JVM agent, no Jetty) works fine on the same 
systems.
   
   ## Error trace (s390x)
   
   ```
   java.net.ConnectException
   Caused by: java.nio.channels.ClosedChannelException
     at sun.nio.ch.SocketChannelImpl.ensureOpen(...)
     at sun.nio.ch.SocketChannelImpl.beginConnect(...)
   ```
   
   ## Fix
   
   Use explicit `127.0.0.1` (IPv4 loopback) as the default host to avoid 
ambiguous `localhost` resolution across architectures.
   
   ## Test plan
   
   - [ ] Run `camel hawtio --port=8888` on x86_64 — verify console is accessible
   - [ ] Run `camel hawtio --host=0.0.0.0 --port=8888` — verify binding to all 
interfaces
   - [ ] Test on s390x/ppc64le (jbang-e2e pipeline)
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to