Posts

Showing posts with the label web

Multiple HTTP connectors in Apache Karaf

Installing the http feature in Karaf leverages Pax Web to embed a Jetty webcontainer. By default, Karaf create a Jetty connector on the 8181 http port (and 8443 for https). You can change this port number by providing etc/org.ops4j.pax.web.cfg file. But, you can also create new connector in the embedded Jetty. You may see several advantages for multiple connectors: you can isolate a set of applications, CXF services, Camel routes on a dedicated port number you can setup a different configuration for each connector. For instance, you can create two SSL connectors, each with a different keystore, truststore, … You can find etc/jetty.xml configuration file where you can create custom Jetty configuration. NB: if you want to have both etc/org.ops4j.pax.web.cfg and etc/jetty.xmll, don’t forget to reference jetty.xml in org.ops4j.pax.web.cfg using the org.ops4j.pax.web.config.file property pointing to the jetty.xml, for instance: # in etc/org.ops4j.pax.web.cfg org.ops4j.pax.web.con...