This chapter explains how to enhance your Apache Karaf with Pax Web to serve as a web container. The OPS4j Pax Web project is an OSGi R4 Http Service and Web Application (refer to Chapter 128, OSGi Enterprise Release 4) implementation. It extends the Http Service with better support for servlet, filters, listeners, error pages, JavaServer Pages (JSPs), and more in order to support the latest Java Servlet spec.
The standard features of Karaf contain a set of options to install Pax Web in different flavors. There are options for: