Never mind, though, I would prefer someone else to spend time on this :)

About 1.1.2 versions - I really don't know exact requirements of each
library I use. Actually I think 1.1.2 are not required by JSF 1.2. But it's
very difficult to check this as I will have to dive into different web
servers and dive into manifest files from each jar file to get the version.
When using app server you always know, which version of app server (not
exact jar files!) you need for required framework version: Tomcat 6+ and GF
2+ for JSF 1.2 and Tomcat 7+, GF 3+ for JSF 2.0. That's simple :)

By the way I tried to restrict EL version using import-package (plus
dynamicImport-Package option):
javax.el;version="2.1.0",
javax.servlet.jsp;version="2.1.0",
org.apache.jasper.compiler;version="2.1.0"

But for some reasons both versions of jsp were imported!!:

javax.servlet.jsp,version=1.1.2 from org.ops4j.pax.web.pax-web-jsp
(163)<http://localhost:8181/system/console/bundles/163>
javax.servlet.jsp,version=2.1.0 from org.ops4j.pax.web.pax-web-jsp
(163)<http://localhost:8181/system/console/bundles/163>

Here is the piece of my Manifest:

Build-Jdk: 1.6.0_20
Export-Package: com.luxoft.drf.web;version="1.0.0.SNAPSHOT",org.apache
 .myfaces.view.facelets.compiler;uses:="javax.el,org.xml.sax.ext,org.x
 ml.sax.helpers,org.xml.sax,javax.xml.parsers";version="2.0.2"
Embed-Directory: WEB-INF/lib
Bundle-ClassPath: .,WEB-INF/classes,WEB-INF/lib/spring-jdbc-3.0.5.RELE
 ASE.jar,WEB-INF/lib/commons-beanutils-1.8.3.jar,WEB-INF/lib/spring-tx
 -3.0.5.RELEASE.jar,WEB-INF/lib/myfaces-impl-2.0.2.jar,WEB-INF/lib/spr
 ing-expression-3.0.5.RELEASE.jar,WEB-INF/lib/commons-logging-1.1.1.ja
 r,WEB-INF/lib/commons-collections-3.2.jar,WEB-INF/lib/commons-lang-2.
 6.jar,WEB-INF/lib/slf4j-jdk14-1.6.1.jar,WEB-INF/lib/spring-context-3.
 0.5.RELEASE.jar,WEB-INF/lib/myfaces-api-2.0.2.jar,WEB-INF/lib/slf4j-a
 pi-1.6.1.jar,WEB-INF/lib/commons-digester-1.8.jar,WEB-INF/lib/primefa
 ces-2.2.1.jar,WEB-INF/lib/spring-beans-3.0.5.RELEASE.jar,WEB-INF/lib/
 spring-aop-3.0.5.RELEASE.jar,WEB-INF/lib/spring-core-3.0.5.RELEASE.ja
 r,WEB-INF/lib/aopalliance-1.0.jar,WEB-INF/lib/commons-codec-1.3.jar,W
 EB-INF/lib/spring-asm-3.0.5.RELEASE.jar,WEB-INF/lib/commons-discovery
 -0.4.jar
Tool: Bnd-1.43.0
Bundle-Name: drfusion-web
DynamicImport-Package: *
Bundle-Version: 1.0.0.SNAPSHOT
Bnd-LastModified: 1314252798262
Embed-Transitive: true
Bundle-ManifestVersion: 2
Bundle-Description: DRFusion web application
Bundle-SymbolicName: drfusion-war
Import-Package: javax.el;version="2.1.0",javax.servlet.jsp;version="2.
 1.0",javax.xml.parsers,org.apache.jasper.compiler;version="2.1.0",org
 .xml.sax,org.xml.sax.ext,org.xml.sax.helpers
Embed-Dependency: *;scope=compile|runtime

Can anyone advise, how to avoid legacy 1.1.2 version?

On Wed, Aug 24, 2011 at 11:52 PM, Achim Nierbeck [via Karaf] <
[email protected]> wrote:

> Ok one thing I really forgot.
>
> Thank you for sharing your experience with it it helps enabling the
> community :-)
>
> regards, Achim
>
> Am 24.08.2011 21:49, schrieb Achim Nierbeck:
>
> Hi,
>
> comments inline:
>
> Am 24.08.2011 21:15, schrieb bitec:
>
> Ok, fixed this one.
>
> As the hack, I removed legacy "export-package" from pax-web-jsp bundle
> Manifest file:
>
>
> ok, I added the el language for convenience to get 1.2 faces running.
>
>  javax.servlet.js
>  p;version="1.1.2",javax.servlet.jsp.el;version="1.1.2",javax.servlet.
>  jsp.jstl.core;version="1.1.2",javax.servlet.jsp.jstl.fmt;version="1.1
>  .2",javax.servlet.jsp.jstl.sql;version="1.1.2",javax.servlet.jsp.jstl
>  .tlv;version="1.1.2"
>
> After this the el language seemed to work ok.
> The better way (will check tomorrow) is to write versions for *javax.el* and
> others explicetely in my import-packages header. By default they got the old
> ones
>
>
> You surely should always make sure you only import the packages you
> require by adding the required version range.
>
>  The fix for tag libraries is borrowed from this
> post:http://groups.google.com/group/spring-osgi/msg/8d12c504c3a6f98d?pli=1
>
> I replaced the DefaultFaceletConfigResourceProvider from myfaces and loaded
> tag libraries explicetely:
>
> URL url1 = getClassLoader().getResource("META-INF/primefaces-i.taglib.xml");
>         URL url2 =
> getClassLoader().getResource("META-INF/primefaces-p.taglib.xml");
>
>         urlSet.add(url2);
>         urlSet.add(url1);
>
>
> I can say, that working with osgi is like terror. The last thing, which I
> didn't solve: images from PF were not loaded successfully. Everything else
> seem to work. Hope my posts will help anyone else
>
>
> it's not OSGi that is the terror here, it's more the issue of all those
> dynamic
> class-loading things that give you hell here :-) JSF in particular is not
> easy to get
>
> the way you want it.
>
> Pax-Web JSP does try to get around this by
> 1) altering the usage of the classloader
> 2) scanning the libraries of the bundle for contained taglibs.
> 3) fails on the using the javax.faces.context.FacesContextFactory for
> initializing M
>
>  --
> View this message in context: 
> http://karaf.922171.n3.nabble.com/JSF-and-apache-servicemix-4-4-0-fuse-00-43-problems-tp3277669p3281853.html
>
> Sent from the Karaf - User mailing list archive at Nabble.com.
>
>
>
> --
> --
> *Achim Nierbeck*
>
>
> Apache Karaf <http://karaf.apache.org/> <http://karaf.apache.org/> Committer 
> & PMC
> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> 
> <http://wiki.ops4j.org/display/paxweb/Pax+Web/>  Committer & Project Lead
> blog <http://notizblog.nierbeck.de/> <http://notizblog.nierbeck.de/>
>
>
>
> --
> --
> *Achim Nierbeck*
>
>
> Apache Karaf <http://karaf.apache.org/> <http://karaf.apache.org/> Committer 
> & PMC
> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> 
> <http://wiki.ops4j.org/display/paxweb/Pax+Web/>  Committer & Project Lead
> blog <http://notizblog.nierbeck.de/> <http://notizblog.nierbeck.de/>
>
>
>
> ------------------------------
>  If you reply to this email, your message will be added to the discussion
> below:
>
> http://karaf.922171.n3.nabble.com/JSF-and-apache-servicemix-4-4-0-fuse-00-43-problems-tp3277669p3281929.html
>  To unsubscribe from JSF and apache-servicemix-4.4.0-fuse-00-43 problems, 
> click
> here<http://karaf.922171.n3.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=3277669&code=YWxpc292ZW5rb0BnbWFpbC5jb218MzI3NzY2OXwyNTk0NjU5MjI=>.
>
>


--
View this message in context: 
http://karaf.922171.n3.nabble.com/JSF-and-apache-servicemix-4-4-0-fuse-00-43-problems-tp3277669p3283128.html
Sent from the Karaf - User mailing list archive at Nabble.com.

Reply via email to