Skip to main content



      Home
Home » Eclipse Projects » Virgo » Unable to load standalone war webapp using JSF 2.0
Unable to load standalone war webapp using JSF 2.0 [message #654517] Wed, 16 February 2011 02:53 Go to next message
Eclipse UserFriend
I am experimenting with Virgo by loading up a standalone JSF 2.0 with Primefaces 2.2.1, and Virgo complains with this message:

Cause: error Exception: org.eclipse.virgo.util.osgi.manifest.parse.BundleManifestPar seException: Error parsing bundle manifest header [javax.faces/com.sun.faces.mojarra-jsf-api] HP003E:[col 11]: Unexpected character '/' (47) HP013E:[col 12]: Expected a semicolon but found 'com' at org.eclipse.virgo.util.osgi.manifest.parse.standard.Standard HeaderParser.parseBundleSymbolicName(StandardHeaderParser.ja va:96) at org.eclipse.virgo.util.osgi.manifest.internal.StandardBundle SymbolicName.parse(StandardBundleSymbolicName.java:33) at org.eclipse.virgo.util.osgi.manifest.internal.BaseParameteri sed.resetFromParseString(BaseParameterised.java:42)


The close i can get is in sun jsf 2.0 api, its manifest file has this entry:

Bundle-SymbolicName: javax.faces/com.sun.faces.mojarra-jsf-api
Implementation-Title: Mojarra

is it a valid entry? Should Virgo care about the isolated webapp's manifest's content?

Thanks all advices

-Dan
Re: Unable to load standalone war webapp using JSF 2.0 [message #654530 is a reply to message #654517] Wed, 16 February 2011 03:55 Go to previous messageGo to next message
Eclipse UserFriend
The OSGi spec does not permit '/' in a bundle symbolic name.

If this JAR is being installed as a bundle into Virgo, Virgo requires that its manifest is invalid. (But Violeta asks some good questions below.)

[Updated on: Wed, 16 February 2011 04:00] by Moderator

Re: Unable to load standalone war webapp using JSF 2.0 [message #654531 is a reply to message #654517] Wed, 16 February 2011 03:56 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

The Bundle-SymbolicName has to follow the syntax:

Bundle-SymbolicName ::= symbolic-name
( ';' parameter ) *

where
digit ::= [0..9]
alpha ::= [a..zA..Z]
alphanum ::= alpha | digit
token ::= ( alphanum | '_' | '-' )+
symbolic-name ::= token('.'token)*

i.e. you cannot use "/"
you can check more about this in the spec [1]

Could you please tell more about your use case i.e. do you put JSF 2.0 binaries inside the web app or you are installing the JSF 2.0 as a regular bundle?
How are you packing your web application?

Regards
Violeta

[1]http://www.osgi.org/download/r4v42/r4.core.pdf
Re: Unable to load standalone war webapp using JSF 2.0 [message #654536 is a reply to message #654531] Wed, 16 February 2011 04:12 Go to previous messageGo to next message
Eclipse UserFriend
Thanks you for the reply, I switch to jsf''s myface and problem go away. Will file a bug against Sun JSF thou

Also, I have jsf api and implementation included under my WEB-INF/lib directory. So this should be a standalone webapp, no share lib/services

-D

[Updated on: Wed, 16 February 2011 04:14] by Moderator

Re: Unable to load standalone war webapp using JSF 2.0 [message #654544 is a reply to message #654531] Wed, 16 February 2011 04:21 Go to previous messageGo to next message
Eclipse UserFriend
I package my webapp as a war file using maven-war-plugin, both jsf api and impl are under WEB-INF/lib

I will file a bug against Sun's JSF

Thanks

-D
Re: Unable to load standalone war webapp using JSF 2.0 [message #654547 is a reply to message #654544] Wed, 16 February 2011 04:30 Go to previous messageGo to next message
Eclipse UserFriend
It could be argued that there is also a bug in Gemini Web as it probably shouldn't be so strict on manifests of JARs in WEB-INF/lib as such JARs need not be treated as OSGi bundles.

However any JARs that have OSGi metadata really should conform to the OSGi syntax so that the JARs can easily be broken out as external dependencies of the web app, so I think we'll let the current behaviour continue.
Re: Unable to load standalone war webapp using JSF 2.0 [message #654741 is a reply to message #654547] Wed, 16 February 2011 17:09 Go to previous messageGo to next message
Eclipse UserFriend
bug filed at http://java.net/jira/browse/JAVASERVERFACES-1954
Re: Unable to load standalone war webapp using JSF 2.0 [message #654803 is a reply to message #654741] Thu, 17 February 2011 04:04 Go to previous messageGo to next message
Eclipse UserFriend
Thanks Dan.
Re: Unable to load standalone war webapp using JSF 2.0 [message #656277 is a reply to message #654803] Thu, 24 February 2011 15:23 Go to previous messageGo to next message
Eclipse UserFriend
Thanks very much for taking the time to file this. It is simple to fix and I will get it fixed promptly.
Re: Unable to load standalone war webapp using JSF 2.0 [message #656321 is a reply to message #654803] Fri, 25 February 2011 01:03 Go to previous messageGo to next message
Eclipse UserFriend
I have committed the fix to the sources for trunk, 2.0, and 2.1 branches.

I have also started modifying the manifests for the maven repository jars at http://download.java.net/maven/2. I started out with Mojarra 2.0.4-b09.

Please confirm that this solves your problem with that version and I'll proceed to write a script that does the rest.

Thanks,

Ed
Re: Unable to load standalone war webapp using JSF 2.0 [message #657502 is a reply to message #656321] Wed, 02 March 2011 21:51 Go to previous messageGo to next message
Eclipse UserFriend
FYI, with the quick fix from Ed, I am able to load my war file to Virgo.

Thanks

-Dan
Re: Unable to load standalone war webapp using JSF 2.0 [message #657816 is a reply to message #657502] Fri, 04 March 2011 03:15 Go to previous message
Eclipse UserFriend
Good to hear. Thanks Ed and Dan.
Previous Topic:Bundle classpath resources fail to load when using ServerOsgiBundleXmlWebApplicationContext
Next Topic:Bundle Logs
Goto Forum:
  


Current Time: Sun Jul 06 07:48:19 EDT 2025

Powered by FUDForum. Page generated in 0.29737 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top