Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-dev] Jetty 8 does not read .tld files inside webapp library jar files

Aleksei,

Oops, got my jsp and jsf jar names mixed up in my email.
Nevertheless, the point is that the jasper jsp compiler from Glassfish that we are using insists
that these jsf tags are loaded ONLY from the container's classpath:

        systemUrisJsf.add("http://java.sun.com/jsf/core");
        systemUrisJsf.add("http://java.sun.com/jsf/html");

Unfortunately, there is no way to modify the lsit of systemUrisJsf with the current code.
Therefore, the only solution for you would be to move the jsf jars (api & impl) into jetty's
lib/jsp.  I urge you to raise a bug, requesting that the systemUrisJsf be able to be
modified (preferably via a ServletContext attribute) with the Glassfish jasper project at:

http://jsp.java.net/

cheers
Jan

On 13 October 2011 16:18, Aleksei Sosnovski <aleksei.sosnovski@xxxxxxxxxxxxxxxxxx> wrote:
I wonder if I can send e-mails with attachments here... Well, I'll give it a try. Application .war file is attached to this e-mail.

In any case, Jetty is displaying an incorrect error message. It says that it can't find a taglib while in reality this taglib is available. 

BR,

Alex.


On Thu, Oct 13, 2011 at 2:47 AM, Jan Bartel <janb@xxxxxxxxxxx> wrote:
Aleksei,

It looks to me with the jsp-2.2 impl from glassfish that is being used in jetty-8.x, that jasper will
not let a webapp override jsf tags like "http://java.sun.com/jsf/core" and "http://java.sun.com/jsf/html"
in WEB-INF/lib. It may well be that having the jsp-impl jar in 2 places is causing jasper problems.

As the jsf jars should be already in jetty's jsp classpath in $JETTY_HOME/lib/jsp you should not
need them in WEB-INF/lib.

If you have a small webapp that you can post, then I'll take a further look at it, but my advice is
to remove the jsp-impl jar from WEB-INF/lib as this is something that the container is supposed
to be providing you, according to javaee specs.

regards
Jan

On 12 October 2011 19:30, Aleksei Sosnovski <aleksei.sosnovski@xxxxxxxxxxxxxxxxxx> wrote:
Hello,

I experience the following problem with Jetty 8 (I tried versions 8.0.1 to the latest one which is 8.0.3).

I have a very simple JSF 1.2 application which basically consists of a single primitive JSP page:

<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
<f:view>
<h:outputText value="#{testBean.test}" />
</f:view>

When I open the page I got the following error: 

/test.jsp(1,58) PWC6188: The absolute uri: http://java.sun.com/jsf/html cannot be resolved in either web.xml or the jar files deployed with this application

The application works OK on Jetty 7.0.2 (haven't tested on other older versions). A required .TLD is inside jsf-impl.jar that is in WEB-INF/lib. Log shows that JSF itself (i.e. classes from this JAR) is loaded.

Now the most interesting part: if I copy jsf-impl.jar to $JETTY_HOME/lib/ext the error disappears.

Has anyone experienced a similar problem? I would understand if Jetty could not parse the .TLD file or did not load jars from WEB-INF/lib, but not parsing .TLD files in webapp libraries but doing so for shared libraries is very strange.

_______________________________________________
jetty-dev mailing list
jetty-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-dev



_______________________________________________
jetty-dev mailing list
jetty-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-dev



_______________________________________________
jetty-dev mailing list
jetty-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-dev



Back to the top