in jbang/jbang-edit/foo.java [18:30]
public void configure() {
from(timer("trigger").period(5000).repeatCount(3))
.to(nettyHttp("https://random-data-api.com/api/v2/banks").keepAlive(true))
.process(e -> {
// use classes from camel-netty-http dependency in the source code
// and have jbang able to generate project with the dependencies ready
// to use in your IDE of choice
NettyHttpMessage msg = e.getMessage(NettyHttpMessage.class);
LOG.info("Netty HTTP response:\n\n\n{}\n\n\n", msg.getHttpResponse());
})
.log("Found bank:")
.to(stream("out"));
}