Re: How to use Pax Web 8.0.16 in karaf 4.4.3?
Hello Worked for me ;) Or at least after I added 8.0.16 feature repo, when you install pax-web feature the newer version will be used. regards Grzegorz Grzybek sob., 25 lut 2023 o 06:25 Jean-Baptiste Onofré napisał(a): > Do you have pax-web features installed ? You can "force" the removal > (feature:repo-remove -u). > > Regards > JB > > On Sat, Feb 25, 2023 at 2:18 AM Paul Spencer > wrote: > > > > Grzegoz, > > > > Removing the pax-web 8.0.15 repo does not remove the repository. Below > is from a fresh install of karaf. > > > > Karaf 4.4.3 > > Java 1.8.0_172 > > Mac OS X 10.16 x86_64 > > > > > > karaf@root()> feature:repo-remove > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > Removing features repository: > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > karaf@root()> feature:repo-list > > Repository│ URL > > > ──┼─ > > org.ops4j.pax.jdbc-1.5.5 │ > mvn:org.ops4j.pax.jdbc/pax-jdbc-features/1.5.5/xml/features > > org.ops4j.pax.web-8.0.15 │ > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > openjpa-3.2.2 │ > mvn:org.apache.openjpa/openjpa-features/3.2.2/xml/features > > aries-jpa-2.7.3 │ > mvn:org.apache.aries.jpa/jpa-features/2.7.3/xml/features > > framework-4.4.3 │ > mvn:org.apache.karaf.features/framework/4.4.3/xml/features > > hibernate-validator-osgi-features │ > mvn:org.hibernate.validator/hibernate-validator-osgi-karaf-features/7.0.2.Final/xml/features > > standard-4.4.3│ > mvn:org.apache.karaf.features/standard/4.4.3/xml/features > > spring-4.4.3 │ > mvn:org.apache.karaf.features/spring/4.4.3/xml/features > > specs-4.4.3 │ > mvn:org.apache.karaf.features/specs/4.4.3/xml/features > > pax-transx-0.5.3 │ > mvn:org.ops4j.pax.transx/pax-transx-features/0.5.3/xml/features > > enterprise-4.4.3 │ > mvn:org.apache.karaf.features/enterprise/4.4.3/xml/features > > org.ops4j.pax.cdi-1.1.4 │ > mvn:org.ops4j.pax.cdi/pax-cdi-features/1.1.4/xml/features > > pax-jms-1.1.2 │ > mvn:org.ops4j.pax.jms/pax-jms-features/1.1.2/xml/features > > karaf@root()> > > > > > On Feb 24, 2023, at 2:50 PM, Grzegorz Grzybek > wrote: > > > > > > Hello > > > > > > Just replace them ;) > > > > > > karaf@root()> feature:repo-remove > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > > Removing features repository: > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > > > > > karaf@root()> feature:repo-add > mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features > > > Adding feature url > mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features > > > > > > And then the features you install will come from 8.0.16. > > > > > > regards > > > Grzegoz Grzybek > > > > > > pt., 24 lut 2023 o 20:48 Paul Spencer > napisał(a): > > > I see that Pax Web version 8.0.16 has been released. How do I utilize > the version 8.0.16 in Karaf 4.4.3? > > > > > > Paul Spencer > > >
[ANN] Apache Karaf Decanter 2.10.0 has been released!
The Apache Karaf team is pleased to announce Apache Karaf Decanter 2.10.0 release. This release is a maintenance release on the Decanter 2.x series, bringing a lot of changes, especially: - a new config allows to define default key in the split parser - fix a ClassCastException in split parser - a bunch of dependency updates You can find details on the Release Notes: https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12311140=12351427 You can find source distribution and installation instructions here: https://karaf.apache.org/download.html Enjoy ! Regards --- The Apache Karaf team
Re: How to use Pax Web 8.0.16 in karaf 4.4.3?
Do you have pax-web features installed ? You can "force" the removal (feature:repo-remove -u). Regards JB On Sat, Feb 25, 2023 at 2:18 AM Paul Spencer wrote: > > Grzegoz, > > Removing the pax-web 8.0.15 repo does not remove the repository. Below is > from a fresh install of karaf. > > Karaf 4.4.3 > Java 1.8.0_172 > Mac OS X 10.16 x86_64 > > > karaf@root()> feature:repo-remove > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > Removing features repository: > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > karaf@root()> feature:repo-list > Repository│ URL > ──┼─ > org.ops4j.pax.jdbc-1.5.5 │ > mvn:org.ops4j.pax.jdbc/pax-jdbc-features/1.5.5/xml/features > org.ops4j.pax.web-8.0.15 │ > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > openjpa-3.2.2 │ > mvn:org.apache.openjpa/openjpa-features/3.2.2/xml/features > aries-jpa-2.7.3 │ > mvn:org.apache.aries.jpa/jpa-features/2.7.3/xml/features > framework-4.4.3 │ > mvn:org.apache.karaf.features/framework/4.4.3/xml/features > hibernate-validator-osgi-features │ > mvn:org.hibernate.validator/hibernate-validator-osgi-karaf-features/7.0.2.Final/xml/features > standard-4.4.3│ > mvn:org.apache.karaf.features/standard/4.4.3/xml/features > spring-4.4.3 │ > mvn:org.apache.karaf.features/spring/4.4.3/xml/features > specs-4.4.3 │ > mvn:org.apache.karaf.features/specs/4.4.3/xml/features > pax-transx-0.5.3 │ > mvn:org.ops4j.pax.transx/pax-transx-features/0.5.3/xml/features > enterprise-4.4.3 │ > mvn:org.apache.karaf.features/enterprise/4.4.3/xml/features > org.ops4j.pax.cdi-1.1.4 │ > mvn:org.ops4j.pax.cdi/pax-cdi-features/1.1.4/xml/features > pax-jms-1.1.2 │ > mvn:org.ops4j.pax.jms/pax-jms-features/1.1.2/xml/features > karaf@root()> > > > On Feb 24, 2023, at 2:50 PM, Grzegorz Grzybek wrote: > > > > Hello > > > > Just replace them ;) > > > > karaf@root()> feature:repo-remove > > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > Removing features repository: > > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > > > karaf@root()> feature:repo-add > > mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features > > Adding feature url > > mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features > > > > And then the features you install will come from 8.0.16. > > > > regards > > Grzegoz Grzybek > > > > pt., 24 lut 2023 o 20:48 Paul Spencer > > napisał(a): > > I see that Pax Web version 8.0.16 has been released. How do I utilize the > > version 8.0.16 in Karaf 4.4.3? > > > > Paul Spencer >
Re: How to use Pax Web 8.0.16 in karaf 4.4.3?
If possible, wait Karaf 4.4.4 that will include it :) Else the cleanest way is probably to create custom build or to replace at runtime. Regards JB On Fri, Feb 24, 2023 at 8:48 PM Paul Spencer wrote: > > I see that Pax Web version 8.0.16 has been released. How do I utilize the > version 8.0.16 in Karaf 4.4.3? > > Paul Spencer
Re: How to use Pax Web 8.0.16 in karaf 4.4.3?
Grzegoz, Removing the pax-web 8.0.15 repo does not remove the repository. Below is from a fresh install of karaf. Karaf 4.4.3 Java 1.8.0_172 Mac OS X 10.16 x86_64 karaf@root()> feature:repo-remove mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features Removing features repository: mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features karaf@root()> feature:repo-list Repository│ URL ──┼─ org.ops4j.pax.jdbc-1.5.5 │ mvn:org.ops4j.pax.jdbc/pax-jdbc-features/1.5.5/xml/features org.ops4j.pax.web-8.0.15 │ mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features openjpa-3.2.2 │ mvn:org.apache.openjpa/openjpa-features/3.2.2/xml/features aries-jpa-2.7.3 │ mvn:org.apache.aries.jpa/jpa-features/2.7.3/xml/features framework-4.4.3 │ mvn:org.apache.karaf.features/framework/4.4.3/xml/features hibernate-validator-osgi-features │ mvn:org.hibernate.validator/hibernate-validator-osgi-karaf-features/7.0.2.Final/xml/features standard-4.4.3│ mvn:org.apache.karaf.features/standard/4.4.3/xml/features spring-4.4.3 │ mvn:org.apache.karaf.features/spring/4.4.3/xml/features specs-4.4.3 │ mvn:org.apache.karaf.features/specs/4.4.3/xml/features pax-transx-0.5.3 │ mvn:org.ops4j.pax.transx/pax-transx-features/0.5.3/xml/features enterprise-4.4.3 │ mvn:org.apache.karaf.features/enterprise/4.4.3/xml/features org.ops4j.pax.cdi-1.1.4 │ mvn:org.ops4j.pax.cdi/pax-cdi-features/1.1.4/xml/features pax-jms-1.1.2 │ mvn:org.ops4j.pax.jms/pax-jms-features/1.1.2/xml/features karaf@root()> > On Feb 24, 2023, at 2:50 PM, Grzegorz Grzybek wrote: > > Hello > > Just replace them ;) > > karaf@root()> feature:repo-remove > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > Removing features repository: > mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features > > karaf@root()> feature:repo-add > mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features > Adding feature url mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features > > And then the features you install will come from 8.0.16. > > regards > Grzegoz Grzybek > > pt., 24 lut 2023 o 20:48 Paul Spencer napisał(a): > I see that Pax Web version 8.0.16 has been released. How do I utilize the > version 8.0.16 in Karaf 4.4.3? > > Paul Spencer
Re: How to use Pax Web 8.0.16 in karaf 4.4.3?
Hello Just replace them ;) karaf@root()> feature:repo-remove mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features Removing features repository: mvn:org.ops4j.pax.web/pax-web-features/8.0.15/xml/features karaf@root()> feature:repo-add mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features Adding feature url mvn:org.ops4j.pax.web/pax-web-features/8.0.16/xml/features And then the features you install will come from 8.0.16. regards Grzegoz Grzybek pt., 24 lut 2023 o 20:48 Paul Spencer napisał(a): > I see that Pax Web version 8.0.16 has been released. How do I utilize the > version 8.0.16 in Karaf 4.4.3? > > Paul Spencer
How to use Pax Web 8.0.16 in karaf 4.4.3?
I see that Pax Web version 8.0.16 has been released. How do I utilize the version 8.0.16 in Karaf 4.4.3? Paul Spencer
Re: Serving static content with Jetty in Karaf 4.4
Hello The documentation, after release of Pax Web 8 is quite outdated... I was thinking about it since I started the refactoring, but you know... Feel free to contribute and/or to open a GitHub ticket. regards Grzegorz Grzybek pt., 24 lut 2023 o 14:35 Kevin Schmidt napisał(a): > Thanks! That did the trick. > > Does an issue need to be opened to get the documentation link I posted up > to date? > > On Thu, Feb 23, 2023 at 11:01 PM Grzegorz Grzybek > wrote: > >> Hello >> >> Pax Web 8 is (modestly speaking) a huge refactoring of Pax Web 7 - mostly >> with respect to context handling for Whiteboard specification. >> I expected that after the upgrade/refactoring, some existing configs and >> setups will stop working - I tried hard (adding hundreds of new integration >> tests) to ensure that new behavior is consistent and compliant to all >> specifications (Servlet API, Whiteboard, HttpService, WAB). >> >> *1. Explaining why your configuration doesn't work* >> >> All your four setups use >> "org.eclipse.jetty.servlet.ServletContextHandler" class which are "almost" >> full web applications - that's why you've correctly assumed you can add a >> servlet there. However Pax Web 8 uses >> org.ops4j.pax.web.service.jetty.internal.PaxWebServletContextHandler >> extension of org.eclipse.jetty.servlet.ServletContextHandler which adds A >> LOT - mostly related to classloading. >> >> I tried your config and simply org.eclipse.jetty.servlet.DefaultServlet >> wasn't found by system class loader - no wonder... >> >> *2. Suggesting better solution* >> >> Jetty (I found it to be ... the most flexible of the 3 embeddable >> runtimes: Jetty, Tomcat, Undertow) has a nice hierarchy of "handlers": >> >> AbstractHandler (org.eclipse.jetty.server.handler) >> AbstractHandlerContainer (org.eclipse.jetty.server.handler) >> HandlerWrapper (org.eclipse.jetty.server.handler) >> ScopedHandler (org.eclipse.jetty.server.handler) >> ContextHandler (org.eclipse.jetty.server.handler) >> ServletContextHandler (org.eclipse.jetty.servlet) >> PaxWebServletContextHandler >> (org.ops4j.pax.web.service.jetty.internal) >> WebAppContext (org.eclipse.jetty.webapp) >> >> And if you need resources, you can just use >> org.eclipse.jetty.server.handler.ContextHandler. >> >> Here's the config which I checked that works: >> >> >> >> >> >> /var/html/test >> /app >> >> > class="org.eclipse.jetty.server.handler.ResourceHandler"> >> true >> >> >> >> >> >> >> I hope this helps ;) >> >> regards >> Grzegorz Grzybek >> >> pt., 24 lut 2023 o 03:57 Kevin Schmidt napisał(a): >> >>> Hi, >>> >>> I came across this page ( >>> http://ops4j.github.io/pax/web/SNAPSHOT/User-Guide.html#adding-specialized-contexthandlers) >>> in the Pax-Web documentation on how to configure Jetty to serve up static >>> content. >>> >>> Trying it with Karaf 4.3.7 works, specifically I take a brand new >>> instance and install the http and webconsole features, and then adding this >>> to jetty.xml allows serving up files in /var/html/test at >>> http://localhost:8181/app/ >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> /app >>> >>> /var/html/test >>> >>> >>> >>> org.eclipse.jetty.servlet.DefaultServlet >>> >>> / >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> However, trying the same thing with 4.4.3 fails. I did it in an >>> instance with a bunch of features already installed and got this warning: >>> >>> 20230223 18:27:19.312 [WARN ] paxweb-config-3-thread-1 (change >>> controller) | 268:org.eclipse.jetty.util:9.4.50.v20221201 | >>> org.eclipse.jetty.xml.XmlConfiguration | Config error at >> name="addHandler"> >>> >>> >>> >>> >>> >>> /app >>> >>> /var/html/test >>> >>> >>> >>> org.eclipse.jetty.servlet.DefaultServlet >>> >>> / >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> 20230223 18:27:19.313 [WARN ] paxweb-config-3-thread-1 (change >>> controller) | 268:org.eclipse.jetty.util:9.4.50.v20221201 | >>> org.eclipse.jetty.xml.XmlConfiguration | Config error at >> name="handler"> >>> >>> >>> >>> >>> >>> >>> >>> /app >>> >>> /var/html/test >>> >>> >>> >>> org.eclipse.jetty.servlet.DefaultServlet >>> >>> / >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> My Karaf 4.3.7 has Jetty 9.4.46 and Pax Web 7.3.25 while Karaf 4.4.3 has >>> Jetty 9.4.50 and Pax Web 8.0.15 >>> >>> Did something change with Jetty config that this is no longer valid? I >>> wouldn't think so with the change from 9.4.46 to 9.4.50 but it clearly >>> doesn't work. >>> >>> I tried
Re: Serving static content with Jetty in Karaf 4.4
Thanks! That did the trick. Does an issue need to be opened to get the documentation link I posted up to date? On Thu, Feb 23, 2023 at 11:01 PM Grzegorz Grzybek wrote: > Hello > > Pax Web 8 is (modestly speaking) a huge refactoring of Pax Web 7 - mostly > with respect to context handling for Whiteboard specification. > I expected that after the upgrade/refactoring, some existing configs and > setups will stop working - I tried hard (adding hundreds of new integration > tests) to ensure that new behavior is consistent and compliant to all > specifications (Servlet API, Whiteboard, HttpService, WAB). > > *1. Explaining why your configuration doesn't work* > > All your four setups use "org.eclipse.jetty.servlet.ServletContextHandler" > class which are "almost" full web applications - that's why you've > correctly assumed you can add a servlet there. However Pax Web 8 uses > org.ops4j.pax.web.service.jetty.internal.PaxWebServletContextHandler > extension of org.eclipse.jetty.servlet.ServletContextHandler which adds A > LOT - mostly related to classloading. > > I tried your config and simply org.eclipse.jetty.servlet.DefaultServlet > wasn't found by system class loader - no wonder... > > *2. Suggesting better solution* > > Jetty (I found it to be ... the most flexible of the 3 embeddable > runtimes: Jetty, Tomcat, Undertow) has a nice hierarchy of "handlers": > > AbstractHandler (org.eclipse.jetty.server.handler) > AbstractHandlerContainer (org.eclipse.jetty.server.handler) > HandlerWrapper (org.eclipse.jetty.server.handler) > ScopedHandler (org.eclipse.jetty.server.handler) > ContextHandler (org.eclipse.jetty.server.handler) > ServletContextHandler (org.eclipse.jetty.servlet) > PaxWebServletContextHandler > (org.ops4j.pax.web.service.jetty.internal) > WebAppContext (org.eclipse.jetty.webapp) > > And if you need resources, you can just use > org.eclipse.jetty.server.handler.ContextHandler. > > Here's the config which I checked that works: > > > > > > /var/html/test > /app > > class="org.eclipse.jetty.server.handler.ResourceHandler"> > true > > > > > > > I hope this helps ;) > > regards > Grzegorz Grzybek > > pt., 24 lut 2023 o 03:57 Kevin Schmidt napisał(a): > >> Hi, >> >> I came across this page ( >> http://ops4j.github.io/pax/web/SNAPSHOT/User-Guide.html#adding-specialized-contexthandlers) >> in the Pax-Web documentation on how to configure Jetty to serve up static >> content. >> >> Trying it with Karaf 4.3.7 works, specifically I take a brand new >> instance and install the http and webconsole features, and then adding this >> to jetty.xml allows serving up files in /var/html/test at >> http://localhost:8181/app/ >> >> >> >> >> >> >> >> >> >> /app >> >> /var/html/test >> >> >> >> org.eclipse.jetty.servlet.DefaultServlet >> >> / >> >> >> >> >> >> >> >> >> >> >> >> However, trying the same thing with 4.4.3 fails. I did it in an instance >> with a bunch of features already installed and got this warning: >> >> 20230223 18:27:19.312 [WARN ] paxweb-config-3-thread-1 (change >> controller) | 268:org.eclipse.jetty.util:9.4.50.v20221201 | >> org.eclipse.jetty.xml.XmlConfiguration | Config error at > name="addHandler"> >> >> >> >> >> >> /app >> >> /var/html/test >> >> >> >> org.eclipse.jetty.servlet.DefaultServlet >> >> / >> >> >> >> >> >> >> >> >> >> 20230223 18:27:19.313 [WARN ] paxweb-config-3-thread-1 (change >> controller) | 268:org.eclipse.jetty.util:9.4.50.v20221201 | >> org.eclipse.jetty.xml.XmlConfiguration | Config error at > name="handler"> >> >> >> >> >> >> >> >> /app >> >> /var/html/test >> >> >> >> org.eclipse.jetty.servlet.DefaultServlet >> >> / >> >> >> >> >> >> >> >> >> >> >> >> My Karaf 4.3.7 has Jetty 9.4.46 and Pax Web 7.3.25 while Karaf 4.4.3 has >> Jetty 9.4.50 and Pax Web 8.0.15 >> >> Did something change with Jetty config that this is no longer valid? I >> wouldn't think so with the change from 9.4.46 to 9.4.50 but it clearly >> doesn't work. >> >> I tried changing the section in jetty.xml to this, using insertHandler >> instead: >> >> >> >> >> >> >> >> /app >> >> /var/html/test >> >> >> >> org.eclipse.jetty.servlet.DefaultServlet >> >> / >> >> >> >> >> >> >> >> >> >> This doesn't have a config error, but instead fails finding the >> DefaultServlet class. >> >>
Re: Custom distribution with Maven assembly has no license
Hi Andre, Karaf distribution itself is created this way, including LICENSE/NOTICE files. You can add LICENSE in the resources, it should be part of the distribution. Regards JB On Fri, Feb 24, 2023 at 10:02 AM Andre Schlegel-Tylla wrote: > > Hello, > > We create a custom Karaf distribution with Maven assembly > (https://karaf.apache.org/manual/latest/#_custom_distributions). But in the > resulting archives the Apache license file is not included. Is this intended? > I think the license have to be included to match the Apache license > requirements. Or am I missing something? > > Regards > Andre >
Custom distribution with Maven assembly has no license
Hello, We create a custom Karaf distribution with Maven assembly ( https://karaf.apache.org/manual/latest/#_custom_distributions). But in the resulting archives the Apache license file is not included. Is this intended? I think the license have to be included to match the Apache license requirements. Or am I missing something? Regards Andre