myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simon <>
Subject Re: freemarker exception
Date Thu, 15 May 2008 22:15:45 GMT

On Thu, 2008-05-15 at 16:43 +0100, James Clinton wrote:
> Does anyone know how to resolve this freemarker error aside from
> including the library?
> I don’t use freemarker and ideally don’t want to add this dependency.
> 2008-05-15 16:31:03,651 ERROR
> [org.apache.myfaces.shared_impl.util.ClassUtils] - Class :
> org.apache.myfaces.renderkit.html.ext.HtmlOutputTextRenderer not
> found.
> java.lang.NoClassDefFoundError:freemarker/template/TemplateException

This renderer class is from tomahawk sandbox (James, if you'd said that
it would have saved me some time).

Class DefaultTemplateEncoder does indeed use freemarker. But as far as I
can see, the DefaultTemplateEncoder class is only loaded if
TemplateRenderer.encodeTemplate is called.

So I would think that an attempt to load this class (and therefore
freemarker) only occurs if you try to use the associated component in
your page. And if you don't want to have freemarker around then you
should avoid using sandbox components that need it..

The sandbox class HtmlOutputTextRenderer does extend TemplateRenderer.
The name is a little suspicious; it sounds initially like a custom
renderer for the standard h:outputText class, but I really doubt that. I
would guess it's just a confusing name, and that it is a renderer for a
special sandbox component.

I don't have time to look any further at the moment.

Martin Marinschek appears to have been the most recent person to work on
this (and that was july last year). Martin?


View raw message