You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Mikolaj Rydzewski <mi...@ceti.pl> on 2010/07/10 20:51:41 UTC

JSF + tag files problem with new Tomcat

Hi,

There's a JSF webapp I maintain. It runs fine on Tomcat 6.0.18. Recently 
I wanted to migrate environment to 6.0.26 but I ran into problems. Due 
to lack of time I just dropped migration idea. Unfortunately the same 
problem exists with Tomcat 6.0.28.

Basically, the problem is with handling JSF specific expressions from 
within tag files. I don't think that use of tag files is forbidden with 
JSF. But I'm not 100% sure though.

So, following code works when in use directly in JSP page:

<h:outputText value="#{app.username}"/>

But when used in a tag file it produces:

#{app.username}

There are no error messages in logs.

So, it used to work before because of some misimplementation in previous 
versions. Or stopped to work now because of misimplementation in newer 
versions :-)

In case someone is interested, here's the source code:
http://www.ceti.pl/~miki/java/jsf-test-case.tar.gz
and war file
http://www.ceti.pl/~miki/java/jsf-test-case.war

-- 
Mikolaj Rydzewski <mi...@ceti.pl>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: JSF + tag files problem with new Tomcat

Posted by Mikolaj Rydzewski <mi...@ceti.pl>.
Mark Thomas wrote:
> In short, no implicit.tld has been defined for the tag library so the
> spec mandates that a JSP version of 2.0 is used. JSP 2.0 doe snot
> support the #{...} syntax for EL so it gets treated as template text.
>
> Prior to the fix, Tomcat incorrectly used JSP 2.1 for implicit tag
> libraries.
>   
Hi Mark,

Thanks for prompt response.

It's good when you've got opportunity to learn new things!
For those who do not know about implicit.tld:
http://download.oracle.com/docs/cd/E17477_01/javaee/5/tutorial/doc/bnamu.html

-- 
Mikolaj Rydzewski <mi...@ceti.pl>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: JSF + tag files problem with new Tomcat

Posted by Mark Thomas <ma...@apache.org>.
On 10/07/2010 19:51, Mikolaj Rydzewski wrote:
> Hi,
> 
> There's a JSF webapp I maintain. It runs fine on Tomcat 6.0.18. Recently
> I wanted to migrate environment to 6.0.26 but I ran into problems. Due
> to lack of time I just dropped migration idea. Unfortunately the same
> problem exists with Tomcat 6.0.28.
> 
> Basically, the problem is with handling JSF specific expressions from
> within tag files. I don't think that use of tag files is forbidden with
> JSF. But I'm not 100% sure though.
> 
> So, following code works when in use directly in JSP page:
> 
> <h:outputText value="#{app.username}"/>
> 
> But when used in a tag file it produces:
> 
> #{app.username}
> 
> There are no error messages in logs.
> 
> So, it used to work before because of some misimplementation in previous
> versions.

This is the reason. It is the result of fixing
https://issues.apache.org/bugzilla/show_bug.cgi?id=48668

In short, no implicit.tld has been defined for the tag library so the
spec mandates that a JSP version of 2.0 is used. JSP 2.0 doe snot
support the #{...} syntax for EL so it gets treated as template text.

Prior to the fix, Tomcat incorrectly used JSP 2.1 for implicit tag
libraries.

Mark



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org