Java – create a web application package (WAB) for the OSGi container, which does not contain all the dependency jars of Maven bundle plugin

I want to deploy a Java webapp (with web. XML and everything) on the top of an OSGi container (such as karaf) and package it in any way (war, jar, I don't care)

>WEB-INF / lib must be empty, and the packaged webapp should find the required class in other bundles installed on the container > the bundle should be a webapp, so the container knows that it must read the web XML to run it and make it available through HTTP services (such as jetty) installed on the container (such as on karaf). > You should use Maven bundle plugin 2.2 0 to complete

I successfully made the bundles and deployed them automatically using the plug - in and Maven - Sling - plugin What I miss is to package my software package as the correct configuration of WAB. I am told that this is a correct package without dependency

Solution

You absolutely need a web XML? I've recently experienced and updated many webapps packaged as war, converting them into pure bundles You usually work on the web Most of the information specified in the XML can also be specified in your manifest for retrieval by Pax web (karaf's front end to the dock) So far, I have not encountered a war that cannot be converted into pure War (which will meet your constraints)

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>