I'm not an OSGi user but here is what I'll do. 1) create a new Maven project with packaging type 'pom' 2) combine all wicket jars in one (uber-jar) there are several approaches here: 1) maven-shade-plugin 2) the way we did it in RC1 with maven-dependency-plugin: see http://repo2.maven.org/maven2/org/apache/wicket/wicket/1.5-RC1/wicket-1.5-RC1.pom
Here check that works with simple Wicket app (e.g. the quickstart). Creating one big jar with all dependendies is against OSGi idea. The goal is to be able to replace dependencies without restarting, e.g. upgrade the service layer without undeploying the presentation. But if you still want to do it: start adding more dependencies to be packed in the uber jar (spring, hibernate) About WicketFilter: - you can use embedded Jetty or Guice Filter and org.apache.wicket.protocol.http.WicketFilter.FILTER_MAPPING_PARAM (I explained this earlier today in another thread) - OSGi 4.1+ has the notion of enterprise OSGi and you can use plain OSGi gymnastics to do that (I have no experience at all in this) On Wed, Apr 6, 2011 at 3:15 PM, Daniele Dellafiore <dani...@dellafiore.net>wrote: > mmm, can't really understand. > > Anyway, I wanted to add that the point here is to deploy a jar on karaf, > not > a war. > To be honest, the real advantage is to deploy a small jar on karaf that is > far better than a heavy war on a jee container. > My idea is to have karaf with all the wicket, spring and other deps, and > that's the easy part. > > Then I need a way to start the WicketFilter in the Karaf context. Normally > the JEE container > looks for the web.xml, that in my case bring to the > SpringWebApplicationFactory and a single spring xml file and from there all > the rest. > > But what if no one looks for the web.xml? Can I say to osgi that my jar is > a > webapp? Or can I start it by hand in an activator or from another file > loaded by spring? > > On Wed, Apr 6, 2011 at 3:57 PM, Martin Grigorov <mgrigo...@apache.org > >wrote: > > > See RC1 o.a.w:wicket:pom.xml > > You'll need to create your own project that will combine the all needed > > .jars as we did in RC1. > > > > On Wed, Apr 6, 2011 at 2:51 PM, Daniele Dellafiore > > <dani...@dellafiore.net>wrote: > > > > > I'd really like to start my wicket app in a osgi (karaf) container. > > > My app uses also wicket-spring. What is the best way to do that now, > with > > > wichet 1.5 rc3? > > > > > > Thanls. > > > > > > On Wed, Mar 16, 2011 at 2:25 PM, Michael O'Cleirigh < > > > michael.ocleir...@rivulet.ca> wrote: > > > > > > > Hello, > > > > > > > > The way releases have been working is that I take the current HEAD > and > > > then > > > > change the wicket.version to the current stable and the pom version > to > > > the > > > > next release. > > > > > > > > If you can commit your changes onto the master branch (wicket > > > 1.5-SNAPSHOT) > > > > then I can create a new 1.5-rc2.1 point release to get the > wicket-osgi > > > > module out into maven central. Just let me know when it works (i.e. > mvn > > > > install works without error) > > > > > > > > You can either fork the repository on github and then do the change > and > > > > file a ticket with a pull request or send a message to the dev list > > with > > > > your github username for push/pull access to the wicketstuff > repository > > > > directly. > > > > > > > > Look at the 'Developer Information' section on the wiki here: > > > > https://github.com/wicketstuff/core/wiki for more details. > > > > > > > > Regards, > > > > > > > > Mike > > > > > > > > > > > > ok, I can take the pom from rc1 and adopt it for rc2 - shouldn't be > > > >> problem since you did the work already. If it works and I find some > > time > > > >> I'll try with github > > > >> > > > >> thanks and regards, > > > >> eike > > > >> > > > >> On [Tue, 15.03.2011 22:10], Martin Grigorov wrote: > > > >> > > > >>> Well, wicketstuff is hosted at GitHub and any user can contribute. > > > >>> If you have some time and willing to share your work with the > > community > > > >>> you > > > >>> can do it yourself. > > > >>> Otherwise just create a ticket in wicketstuff's issue tracking > system > > > and > > > >>> someone of us will do it when we have some time. > > > >>> > > > >>> Thanks for testing the RCs ! ;-) > > > >>> > > > >>> On Tue, Mar 15, 2011 at 9:21 PM, Eike Kettner<n...@eknet.org> > > wrote: > > > >>> > > > >>> Hi Martin, > > > >>>> > > > >>>> thanks for your response and no need to apologize! It's good to > have > > > rcX > > > >>>> candidate releases to play with so issues can be found. > > > >>>> > > > >>>> For me a wicket-osgi dependency would be great! And I really don't > > > care > > > >>>> about where to download :) I don't think that providing it from > > > >>>> wicketstuff > > > >>>> would bother users... > > > >>>> > > > >>>> If you decide to not support osgi out-of-the-box, it's still no > > > problem > > > >>>> to create an aggregate jar myself. I'd think most osgi users have > to > > > do > > > >>>> this (unfortunately) quite often to add other "no-bundle-jars". > But > > > >>>> with a distributed jar, it's of course a lot easier - I would > > > appreciate > > > >>>> it (as probably other osgi users would). > > > >>>> > > > >>>> regards, > > > >>>> Eike > > > >>>> > > > >>>> On [Tue, 15.03.2011 20:43], Martin Grigorov wrote: > > > >>>> > > > >>>>> Hi Eike, > > > >>>>> > > > >>>>> Sorry that we broke OSGi support again. > > > >>>>> The problem was that many users wanted -sources and -javadoc for > > the > > > >>>>> aggregate .jar and it became a bit complex and confusing. > > > >>>>> > > > >>>>> I think we can add wicket-osgi project in wicketstuff/core > > repository > > > >>>>> > > > >>>> that > > > >>>> > > > >>>>> will do the same we did initially in WICKET-3088 and then you > will > > > use > > > >>>>> org.wicketstuff:wicket-osgi dependency instead. We release > > > wicketstuff > > > >>>>> > > > >>>> core > > > >>>> > > > >>>>> projects few days after Wicket releases. > > > >>>>> > > > >>>>> Other opinions/suggestions ? > > > >>>>> > > > >>>>> martin-g > > > >>>>> > > > >>>>> On Tue, Mar 15, 2011 at 3:05 PM, Eike Kettner<n...@eknet.org> > > > wrote: > > > >>>>> > > > >>>>> Hi, > > > >>>>>> > > > >>>>>> I'm using wicket 1.5-RC1 in an OSGi container. There was an > issue > > > when > > > >>>>>> upgrading related to package names > > > >>>>>> (https://issues.apache.org/jira/browse/WICKET-3088) > > > >>>>>> > > > >>>>>> Now I tried upgrading to 1.5-rc2 and found that there is no > > > aggregate > > > >>>>>> jar file anymore. I then read the discussion-thread "[discuss] > How > > > to > > > >>>>>> resolve wicket aggregate classes / sources jar issues". > > > >>>>>> (nabble: > > > >>>>>> > > > >>>>>> > > > >>>>>> > > > >>>> > > > > > > http://apache-wicket.1842946.n4.nabble.com/discuss-How-to-resolve-wicket-aggregate-classes-sources-jar-issues-td3234420.html > > > >>>> ) > > > >>>> > > > >>>>> As it states, the aggregate jar has been removed from the wicket > > > >>>>>> distribution. Now, this introduces the very same issues > described > > in > > > >>>>>> WICKET-3088 again. > > > >>>>>> > > > >>>>>> While I can just repackage wicket myself and create a aggregate > > jar > > > to > > > >>>>>> feed the osgi container, it is first more inconvenient :) and > > > >>>>>> secondly, > > > >>>>>> there is then no real reason to have the wicket-xxx jars export > > > >>>>>> packages, as they won't work in an OSGi container one by one > > > anyways. > > > >>>>>> I > > > >>>>>> cannot add all single jars to the osgi container, because of the > > > >>>>>> > > > >>>>> clashes > > > >>>> > > > >>>>> in export-package. > > > >>>>>> > > > >>>>>> so in summary, there is another use case where the aggregate jar > > is > > > >>>>>> really helpful: when using wicket with osgi. But it only is, > > because > > > >>>>>> the single wicket jars export the same packages (for example, > > > >>>>>> wicket-request and wicket-core both export > > > >>>>>> org.apache.wicket.request.handler). > > > >>>>>> > > > >>>>>> Are there any thoughts of adding this aggregate jar to the > > > >>>>>> distribution > > > >>>>>> back again? > > > >>>>>> > > > >>>>>> kind regards, > > > >>>>>> eike > > > >>>>>> > > > >>>>>> > > > --------------------------------------------------------------------- > > > >>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > > > >>>>>> For additional commands, e-mail: users-h...@wicket.apache.org > > > >>>>>> > > > >>>>>> > > > >>>>>> > > > >>>>> -- > > > >>>>> Martin Grigorov > > > >>>>> jWeekend > > > >>>>> Training, Consulting, Development > > > >>>>> http://jWeekend.com<http://jweekend.com/> > > > >>>>> > > > >>>> -- > > > >>>> email: e...@eknet.org https://www.eknet.org pgp: 481161A0 > > > >>>> > > > >>>> > > --------------------------------------------------------------------- > > > >>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > > > >>>> For additional commands, e-mail: users-h...@wicket.apache.org > > > >>>> > > > >>>> > > > >>>> > > > >>> -- > > > >>> Martin Grigorov > > > >>> jWeekend > > > >>> Training, Consulting, Development > > > >>> http://jWeekend.com<http://jweekend.com/> > > > >>> > > > >> > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > > > > For additional commands, e-mail: users-h...@wicket.apache.org > > > > > > > > > > > > > > > > > > > -- > > Martin Grigorov > > jWeekend > > Training, Consulting, Development > > http://jWeekend.com <http://jweekend.com/> > > > -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com <http://jweekend.com/>