Hi Dan, I'm pretty sure it uses the bundlor tool of spring / gemini (whatsoever ;) ) Maybe if I find time I'll try how this compares to bnd. Though it still needs to do a lot of magic and the magic done by bnd does have some limits cause it only scans the bytecode and the xml files (and some others I'm sure).
regards, Achim :) 2012/6/30 Dan Tran <[email protected]>: > Actually I have not touched virgo for at least a year. However as i > recall, loading a vanilla war file is very transparent, Virgo does the > magic behind the scene. All I did, is just dropped my war into a Virgo > hot deploy folder and the magic happens > > Thanks > > -Dan > > > On Fri, Jun 29, 2012 at 3:23 AM, Achim Nierbeck <[email protected]> > wrote: >> Hi Dan, >> >> ok, coming back to your issue, since talking of virgo :) >> did you try what the spring-bundlor does to the standard war and how >> it looks different >> to what the bnd tool (either as maven-bundle or used with the >> wrap-protokol) does >> to the war in question. >> >> I'm pretty sure we at ops4j would also love some contribution for an >> alternative wrap >> url handler that uses spring-bundlor ;) >> >> regards, Achim >> >> 2012/6/28 Dan Tran <[email protected]>: >>> Hi Achim >>> >>> Sorry about offending in any way, you have been very responsive of all >>> of my inquiries >>> >>> -Dan >>> >>> On Wed, Jun 27, 2012 at 11:57 PM, Achim Nierbeck >>> <[email protected]> wrote: >>>> Hi Dan, >>>> >>>> thanx for pointing to Virgo, >>>> unfortunately I'm "a not good enough" [1] >>>> therefore I do not get paid for working on this, I >>>> solely do this in my spare time for fame and fortune. >>>> >>>> regards, Achim >>>> >>>> [1] - >>>> http://journal.dedasys.com/2012/03/22/im-not-good-enough-to-work-on-open-source-software >>>> >>>> 2012/6/28 Dan Tran <[email protected]>: >>>>> Ah, I totally forgot about that requirement. Will look into it. >>>>> >>>>> btw, Virgo works great with vanilla webapp out of the box >>>>> >>>>> Thanks >>>>> >>>>> -Dan >>>>> >>>>> >>>>> On Tue, Jun 26, 2012 at 1:47 AM, Achim Nierbeck <[email protected]> >>>>> wrote: >>>>>> Hi Dan, >>>>>> >>>>>> how does your URL look like? >>>>>> With spring based web-app this can be a bit more tricky. >>>>>> For the following reason, when having a non OSGi >>>>>> Webapplication you need to install it a webbundle. >>>>>> The URL-Handler taking care of this will try to make the >>>>>> non-osgi war a web application bundle analyzing the dependencies >>>>>> and so forth based on the classfiles with the BND tool. >>>>>> As it uses BND it only works as good as the standalone BND >>>>>> tool can be. Therefore any dynamically loaded class that is contained >>>>>> in a string can not be found as a dependency. >>>>>> To get this working you need to give the webbundle URL handler >>>>>> some hints on how to improve the import-packages by >>>>>> adding those parameters to the install commando. >>>>>> Like: >>>>>> >>>>>> install >>>>>> webbundle:mvn:groupid/artefactid/version?Import-Package=com.my.package;version=0.1.0,another.package&Web-ContextPath=testme >>>>>> >>>>>> >>>>>> some more details on what needs to be set in a WebApplicationBundle >>>>>> can be found at [1] >>>>>> >>>>>> regards, Achim >>>>>> >>>>>> [1] - http://team.ops4j.org/wiki/display/paxweb/OSGi-fy+your+WAR >>>>>> >>>>>> >>>>>> 2012/6/25 Dan Tran <[email protected]>: >>>>>>> May be this issue relates to this link >>>>>>> http://stackoverflow.com/questions/8118404/osgi-expose-an-classnotfoundexception-org-w3c-dom-error-when-release >>>>>>> ?? >>>>>>> >>>>>>> -D >>>>>>> >>>>>>> On Thu, Jun 21, 2012 at 8:50 PM, Dan Tran <[email protected]> wrote: >>>>>>>> Hi >>>>>>>> >>>>>>>> I am continuing my quest to get a vanila spring webapp war file to >>>>>>>> load on karaf >>>>>>>> >>>>>>>> The example is at >>>>>>>> https://src.springframework.org/svn/spring-samples/petcare/trunk. This >>>>>>>> example loads perfectly on my tomcat7.0.27 + jdk7 >>>>>>>> >>>>>>>> Under karaf, after features:install war >>>>>>>> >>>>>>>> karaf fails to load my petcare.war the first time with following >>>>>>>> errror. ( dont see this under karaf 2.2.7 ) >>>>>>>> >>>>>>>> >>>>>>>> 2012-06-21 20:36:09,256 | ERROR | -SNAPSHOT/deploy | fileinstall >>>>>>>> | 19 - org.apache.felix.fileinstall - 3.2.4 | Failed to >>>>>>>> install artifact: C:\Users\Dan.Tran\dev\karaf\apache-karaf >>>>>>>> -3.0.0-SNAPSHOT\deploy\petcare.war >>>>>>>> java.lang.IllegalStateException: Unknown protocol: webbundle >>>>>>>> at >>>>>>>> org.apache.felix.framework.URLHandlersStreamHandlerProxy.toExternalForm(URLHandlersStreamHandlerProxy.java:481)[org.apache.felix.framework-4.0.2.jar:] >>>>>>>> at >>>>>>>> org.apache.felix.framework.URLHandlersStreamHandlerProxy.toExternalForm(URLHandlersStreamHandlerProxy.java:474)[org.apache.felix.framework-4.0.2.jar:] >>>>>>>> at java.net.URL.toExternalForm(URL.java:919)[:1.7.0_03] >>>>>>>> at java.net.URL.toString(URL.java:905)[:1.7.0_03] >>>>>>>> at >>>>>>>> org.apache.felix.fileinstall.internal.DirectoryWatcher.install(DirectoryWatcher.java:937)[19:org.apache.felix.fileinstall:3.2.4] >>>>>>>> at >>>>>>>> org.apache.felix.fileinstall.internal.DirectoryWatcher.install(DirectoryWatcher.java:854)[19:org.apache.felix.fileinstall:3.2.4] >>>>>>>> at >>>>>>>> org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:483)[19:org.apache.felix.fileinstall:3.2.4] >>>>>>>> at >>>>>>>> org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:291)[19:org.apache.felix.fileinstall:3.2.4] >>>>>>>> >>>>>>>> >>>>>>>> After restarting my karaf >>>>>>>> >>>>>>>> here is the next error ( same for all version of karaf ) >>>>>>>> >>>>>>>> 2012-06-21 20:47:02,921 | ERROR | raf-2.2.7/deploy | >>>>>>>> RegisterWebAppVisitorWC | 77 - >>>>>>>> org.ops4j.pax.web.pax-web-extender-war - 1.0.9 | Registration >>>>>>>> exception. Skipping. >>>>>>>> java.lang.RuntimeException: >>>>>>>> org.springframework.beans.factory.BeanDefinitionStoreException: >>>>>>>> Unexpected exception parsing XML document from class path resource >>>>>>>> [META-INF/spring/root-context.xml]; neste >>>>>>>> d exception is java.lang.NoClassDefFoundError: org/w3c/dom/DOMError >>>>>>>> at >>>>>>>> org.eclipse.jetty.servlet.ServletHandler.updateMappings(ServletHandler.java:1225)[62:org.eclipse.jetty.servlet:7.5.4.v20111024] >>>>>>>> >>>>>>>> >>>>>>>> Thanks >>>>>>>> >>>>>>>> -D >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> >>>>>> Apache Karaf <http://karaf.apache.org/> Committer & PMC >>>>>> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> >>>>>> Committer & Project Lead >>>>>> OPS4J Pax for Vaadin >>>>>> <http://team.ops4j.org/wiki/display/PAXVAADIN/Home> Commiter & Project >>>>>> Lead >>>>>> blog <http://notizblog.nierbeck.de/> >>>> >>>> >>>> >>>> -- >>>> >>>> Apache Karaf <http://karaf.apache.org/> Committer & PMC >>>> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> >>>> Committer & Project Lead >>>> OPS4J Pax for Vaadin >>>> <http://team.ops4j.org/wiki/display/PAXVAADIN/Home> Commiter & Project >>>> Lead >>>> blog <http://notizblog.nierbeck.de/> >> >> >> >> -- >> >> Apache Karaf <http://karaf.apache.org/> Committer & PMC >> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> >> Committer & Project Lead >> OPS4J Pax for Vaadin >> <http://team.ops4j.org/wiki/display/PAXVAADIN/Home> Commiter & Project >> Lead >> blog <http://notizblog.nierbeck.de/> -- Apache Karaf <http://karaf.apache.org/> Committer & PMC OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer & Project Lead OPS4J Pax for Vaadin <http://team.ops4j.org/wiki/display/PAXVAADIN/Home> Commiter & Project Lead blog <http://notizblog.nierbeck.de/>
