DESCRIPTION
============================================
If running in an 'older' JSP container, LifecycleImpl throws a
NullPointerException when registering ELResolvers. This is because the
CompositeELResolver was never set on the ApplicationAssociate by the
ConfigureListener.
The method that sets the CompositeELResolver on the ApplicationAssociate will
properly exit if it's not running in a JSP 2.1 container (thanks btw), but we
need to guarantee that the JSFCompositeELResolver first gets set on the
ApplicationAssociate.
I'm submitting a patch that just involves moving the JSFCompositeELResolver
declaration above the JSP 2.1 integration code. This corrected the issue and
Facelets is able to run in JSP 1.2.
PATCH
============================================
RCS file:
/cvs/javaserverfaces-sources/jsf-ri/src/com/sun/faces/config/ConfigureListener.java,v
retrieving revision 1.37
diff -r1.37 ConfigureListener.java
1322a1323,1331
>
> ApplicationAssociate appAssociate = ApplicationAssociate
> .getInstance(getExternalContextDuringInitialize());
>
> // register an empty resolver for now. It will be populated
after the
> // first request is serviced.
> CompositeELResolver compositeELResolverForJsp = new
FacesCompositeELResolver();
> appAssociate.setFacesELResolverForJsp(compositeELResolverForJsp);
>
1342,1349d1350
< ApplicationAssociate appAssociate =
<
ApplicationAssociate.getInstance(getExternalContextDuringInitialize());
<
< // register an empty resolver for now. It will be populated
after the
< // first request is serviced.
< CompositeELResolver compositeELResolverForJsp =
< new FacesCompositeELResolver();
< appAssociate.setFacesELResolverForJsp(compositeELResolverForJsp);