Chapter 24. web
The web application is a bundle, so we can use normal bundle:start
and bundle:stop
commands.
The recommended method is to use WAB bundles, that have the Web-ContextPath: /path
manifest header.
WAB bundles can be installed as the type war
:
Example
mvn:io.hawt/hawtio-osgi/2.0.0.fuse-7_12_0-00009/war
.
24.1. web:context-list Copy linkLink copied to clipboard!
24.1.1. Description Copy linkLink copied to clipboard!
Lists all available web contexts. These may originate from HttpService, Whiteboard or WAB Extender.
24.1.2. Syntax Copy linkLink copied to clipboard!
web:context-list
24.1.3. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--help | Display this help message |
24.1.4. Additional information Copy linkLink copied to clipboard!
This command is mostly useful for OSGi web application developers.
Bundle ID | Symbolic Name | Context Path | Context Name | Rank | Service ID | Type | Scope | Registration Properties |
---|---|---|---|---|---|---|---|---|
122 | org.apache.cxf.cxf-rt-transports-http | / | default | MAX | 0 | HttpService | static* | httpContext.id=default httpContext.path=/ osgi.http.whiteboard.context.httpservice=default osgi.http.whiteboard.context.path=/ |
230 | org.ops4j.pax.web.pax-web-extender-whiteboard | / | default | 0 | 0 | Whiteboard | static* | osgi.http.whiteboard.context.name=default osgi.http.whiteboard.context.path=/ |
43 | io.hawt.hawtio-osgi | /hawtio | /hawtio | MAX | 0 | WAB | static* | osgi.http.whiteboard.context.path=/hawtio |
24.2. web:launch Copy linkLink copied to clipboard!
24.2.1. Description Copy linkLink copied to clipboard!
Start the web application in a browser of the given bundle ID.
24.2.2. Syntax Copy linkLink copied to clipboard!
web:launch [options] id
24.2.3. Arguments Copy linkLink copied to clipboard!
Name | Description |
---|---|
id | The bundle ID to start the browser with |
24.2.4. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--base | The base URL to browse to, otherwise default localhost:8181 will be used. |
--help | Display this help message |
24.3. web:wab-list Copy linkLink copied to clipboard!
24.3.1. Description Copy linkLink copied to clipboard!
Lists all available, deployed Web Application Bundles.
24.3.2. Syntax Copy linkLink copied to clipboard!
web:wab-list
24.3.3. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--help | Display this help message |
24.4. web:servlet-list Copy linkLink copied to clipboard!
24.4.1. Description Copy linkLink copied to clipboard!
Lists details for available servlets.
24.4.2. Syntax Copy linkLink copied to clipboard!
web:servlet-list [options]
24.4.3. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--help | Display this help message |
--no-format | Disable table rendered output |
24.4.4. Additional information Copy linkLink copied to clipboard!
The web:servlet-list
command lists installed servlets, showing additional information, for example the method of servlet registration.
Bundle ID | Name | Class | Context Path(s) | URLs | Type |
---|---|---|---|---|---|
43 | default | org.ops4j.pax.web.service.undertow.internal.web.UndertowResourceServlet | /hawtio | / | WAB |
43 | jolokia-agent | io.hawt.web.servlets.JolokiaConfiguredAgentServlet | /hawtio | /jolokia/* | WAB |
43 | jolokia-proxy | io.hawt.web.proxy.ProxyServlet | /hawtio | /proxy/* | WAB |
43 | jsp | org.ops4j.pax.web.jsp.JspServlet | /hawtio | *.jspx, *.jsp | WAB |
43 | keycloak | io.hawt.web.auth.keycloak.KeycloakServlet | /hawtio | /keycloak/* | WAB |
43 | login | io.hawt.web.auth.LoginServlet | /hawtio | /auth/login | WAB |
43 | logout | io.hawt.web.auth.LogoutServlet | /hawtio | /auth/logout | WAB |
43 | plugin | io.hawt.web.plugin.PluginServlet | /hawtio | /plugin/* | WAB |
43 | user | io.hawt.web.auth.keycloak.KeycloakUserServlet | /hawtio | /user/* | WAB |
122 | cxf-osgi-transport-servlet | org.apache.cxf.transport.servlet.CXFNonSpringServlet | / | /cxf/* | HttpService |
24.5. web:start Copy linkLink copied to clipboard!
- Deprecated
-
Use
bundle:start
with WAB bundles instead.
24.5.1. Description Copy linkLink copied to clipboard!
Start the web context of given bundles.
24.5.2. Syntax Copy linkLink copied to clipboard!
web:start [options] ids
24.5.3. Arguments Copy linkLink copied to clipboard!
Name | Description |
---|---|
ids | The list of bundle IDs separated by whitespaces |
24.5.4. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--help | Display this help message |
24.6. web:stop Copy linkLink copied to clipboard!
- Deprecated
-
Use
bundle:stop
with WAB bundles instead.
24.6.1. Description Copy linkLink copied to clipboard!
Stop the web context of given bundles.
24.6.2. Syntax Copy linkLink copied to clipboard!
web:stop [options] ids
24.6.3. Arguments Copy linkLink copied to clipboard!
Name | Description |
---|---|
ids | The list of bundle IDs separated by whitespaces |
24.6.4. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--help | Display this help message |
24.7. web:wab-info Copy linkLink copied to clipboard!
24.7.1. Description Copy linkLink copied to clipboard!
Shows information about Web Application Bundle.
24.7.2. Syntax Copy linkLink copied to clipboard!
web:wab-info [options]
24.7.3. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--wab | WAB specified by context path or bundle ID |
--help | Display this help message |
24.7.4. Additional information Copy linkLink copied to clipboard!
The web:wab-info
command shows information about the structure of a web application. It displays reachable bundles, WAB classpath and registered ServletContainerInitializers.
Sample output for hawtio web application
24.8. web:wab-list Copy linkLink copied to clipboard!
24.8.1. Description Copy linkLink copied to clipboard!
Lists all available, deployed Web Application Bundles.
24.8.2. Syntax Copy linkLink copied to clipboard!
web:wab-list
24.8.3. Options Copy linkLink copied to clipboard!
Name | Description |
---|---|
--help | Display this help message |