Thank you four your responses guys. @Achim: It seems that using PAX Web is the easiest way. So I would like to add a servlet in an existing maven projet.
How may I start the servlet at runtime of my bundle using PAX Web (without the Activator ? Regards On 23 March 2016 at 16:05, Jean-Baptiste Onofré <j...@nanthrax.net> wrote: > Good point and kudo to Achim. > > I'm humbly apologize to the Pax Web master ;) > > Regards > JB > > On 03/23/2016 04:02 PM, Achim Nierbeck wrote: > >> Hi, >> >> The only real source for samples are the PAX Web samples ;-) >> You'll find a bunch of samples and how the integration tests work at: >> >> https://github.com/ops4j/org.ops4j.pax.web/tree/master/samples >> >> And >> >> >> org.ops4j.pax.web/tree/master/pax-web-itest/pax-web-itest-container/pax-web-itest-container-jetty >> >> Regards, Achim >> >> sent from mobile device >> >> Am 23.03.2016 3:56 nachm. schrieb "Jean-Baptiste Onofré" >> <j...@nanthrax.net <mailto:j...@nanthrax.net>>: >> >> Hi, >> >> yes, you can take a look on: >> >> >> https://github.com/jbonofre/karaf-boot/tree/master/karaf-boot-samples/karaf-boot-sample-servlet >> >> Basically, the easiest way is to use the @WebServlet annotation, and >> install the http-whiteboard feature. >> >> The http-whiteboard feature will "listen" for servlet and expose in >> the Karaf WebContainer. >> >> Regards >> JB >> >> On 03/23/2016 03:47 PM, Alioune wrote: >> >> Hi All, >> >> I am trying to run a servlet in karaf contaire, I have >> successfully done >> that using ServiceTracker. >> Now I would like to set a filter for the servlet, but I have no >> idea >> about doing that with ServiceTracker. >> I have a few questions : >> 1: are there others ways than ServiceTracker to run servlet in >> karaf ? >> 2: How may I create a filter for servlet running in karaf ? >> 3: Is there a mean to use the default web.xml ? >> >> Regards, >> >> >> -- >> Jean-Baptiste Onofré >> jbono...@apache.org <mailto:jbono...@apache.org> >> http://blog.nanthrax.net >> Talend - http://www.talend.com >> >> > -- > Jean-Baptiste Onofré > jbono...@apache.org > http://blog.nanthrax.net > Talend - http://www.talend.com >