>>>>> Steinar Bang <[email protected]>:

> In my quest to get my webapps ported from openjdk-8 to openjdk-11 I've
> run into the issue, with "requirement missing osgi.ee=UNKNOWN", ie:
>  org.apache.felix.resolver.reason.ReasonException: Unable to resolve root: 
> missing requirement [root] osgi.identity; osgi.identity=handlereg-with-derby; 
> type=karaf.feature; version="[1.0.0.SNAPSHOT,1.0.0.SNAPSHOT]"; 
> filter:="(&(osgi.identity=handlereg-with-derby)(type=karaf.feature)(version>=1.0.0.SNAPSHOT)(version<=1.0.0.SNAPSHOT))"
>  [caused by: Unable to resolve handlereg-with-derby/1.0.0.SNAPSHOT: missing 
> requirement [handlereg-with-derby/1.0.0.SNAPSHOT] osgi.identity; 
> osgi.identity=handlereg-web-frontend; type=karaf.feature [caused by: Unable 
> to resolve handlereg-web-frontend/1.0.0.SNAPSHOT: missing requirement 
> [handlereg-web-frontend/1.0.0.SNAPSHOT] osgi.identity; 
> osgi.identity=no.priv.bang.handlereg.web.frontend; type=osgi.bundle; 
> version="[1.0.0.SNAPSHOT,1.0.0.SNAPSHOT]"; resolution:=mandatory [caused by: 
> Unable to resolve no.priv.bang.handlereg.web.frontend/1.0.0.SNAPSHOT: missing 
> requirement [no.priv.bang.handlereg.web.frontend/1.0.0.SNAPSHOT] osgi.ee; 
> filter:="(osgi.ee=UNKNOWN)"]]]

> The cure for this issue is moving to the newest version of
> maven-bundle-plugin, ie. 4.2.0
>  https://stackoverflow.com/a/51155158

> And version 4.2.0 of maven-bundle-plugin does the right thing in the
> manifest.mf. The require-capabilities header looks like this:
>  Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=11))"

> However, usign maven-bundle-plugin 4.2.0 makes my webapp fail.  The web
> context fails in start.

> Does anyone know if this there are known issues with maven-bundle-plugin 4.2.0
> (or 4.1.0, which fails in the same way) and the web whiteboard...?

> Here are the error messages from karaf.log, that occurs on startup when
> the application has been build using maven-bundle-plugin 4.1.0 or 4.2.0:

Sorry! Wrong first log message.

This is the first error after karaf startup:
 https://gist.github.com/steinarb/d0b6972df59e4d51a9292756fb5f3ef1

Then a while later, comes the failure to start the servlet context:
 https://gist.github.com/steinarb/e4f7eb493733c1d09261affe5bbc6411

There is something weird going on with the web whiteboard.  Perhaps I
should look into upgrading pax-web...?

Reply via email to