Forums Register Login

Glassfish runtime for JSF

+Pie Number of slices to send: Send
i'm little confused with the way glassfish behaves in respect to libraries
i have a jsf 1.2 application(bundled run time in war) deployed on glassfish 3.1.1 server...
when the request/response headers are tracked it shows the jsf version as 2.0
does any one know the reason why it was doing that? your help is really appriciated...
+Pie Number of slices to send: Send
I don't think I really understand it myself, but glassfish needs jsf for the admin console and uses the JSF version from
$INSTALL_DIR/glassfish/modules directory (used to be jsf-api.jar & jsf-impl.jar, now replaced by javax.faces.jar).

When you start the glassfish server this is the version that is output in the server log. My maven project has a
dependency on JSF as follows:



so that's the verson I'd expect my project to use, and I have to say I always keep the version in the modules folder
and the version referenced from my pom.xml the same, although I'd not expect them to have to be. This doesn't
really answer your question, which is an interesting one.

Regards,
Brendan.
+Pie Number of slices to send: Send
Thank you for the reply Brendan...

the dependency you have mentioned will pull the libraries from Glassfish right?
what if you have a dependency like this...?

<dependency>
<groupId>javax.faces</groupId>
<artifactId>jsf-api</artifactId>
<version>1.2</version>
</dependency>

can you track the request/response headers? what version would you expect to see?
+Pie Number of slices to send: Send
Up-to-date JEE servers have JSF built into them. Not because it's required by admin apps, but because it's part of the JEE standard (Note that this is JEE and not J2EE).

An exception to this is the Tomcat webapp server, but that doesn't apply here.

If, however, you need to run with a different version of JSF than what the server provides and you cannot obtain or use a more appropriate version of the server, there's usually a way to override the JSF jars. It depends on the server, though, so check the GlassFish documentation.
+Pie Number of slices to send: Send
Thanks for the suggestion Tim.
i did try to override the jars using the following property in glassfish-web.xml. however, it didnt work.
when the Glassfish server is started, it throws a warning "ignoring invalid property".

i'm trying hard to look/search for available properties in Glassfish 3.1.1.
is there a place or documentation where it can give more information on the available properties?
+Pie Number of slices to send: Send

Only slightly different but I thought it was like this:


+Pie Number of slices to send: Send
thank you Brendan...
it works now...

Thank you so much Brendan and Tim
For my next trick, I'll need the help of a tiny ad ...
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 4438 times.
Similar Threads
Java Application Client Project
Primefaces Layout only shows Center when there should be North, South, East and West as well
DTD factory class org.apache.xerces.impl.dv.dtd.DTDDVFactoryImpl does not extend from DTDDVFactory
The class '<name>' does not have the property '<name>'.
Lost Sessions on Clustering
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 02:25:34.