JSF 1.2_03 NullPointerException w/Resin 3.1

Has anybody seen this before? I am unable to load any pages due to an NPR apparently while processing the <f:view> tag.

The full stack trace is:

08:49:22.519 [ErrorPageManager] WARNING java.lang.NullPointerException

08:49:22.519at javax.faces.webapp.UIComponentClassicTagBase.getFacesContext(UIComponentClassicTagBase.java:1758)

08:49:22.519at javax.faces.webapp.UIComponentClassicTagBase.isIncluded(UIComponentClassicTagBase.java:1647)

08:49:22.519at javax.faces.webapp.UIComponentClassicTagBase.setJspId(UIComponentClassicTagBase.java:1575)

08:49:22.519at _jsp._hello__jsp._jspService(_hello__jsp.java:46)

08:49:22.519at com.caucho.jsp.JavaPage.service(JavaPage.java:61)

08:49:22.519at com.caucho.jsp.Page.pageservice(Page.java:586)

08:49:22.519at com.caucho.server.dispatch.PageFilterChain.doFilter(PageFilterChain.java:190)

08:49:22.519at com.caucho.server.webapp.DispatchFilterChain.doFilter(DispatchFilterChain.java:97)

08:49:22.519at com.caucho.server.dispatch.ServletInvocation.service(ServletInvocation.java:226)

08:49:22.519at com.caucho.server.webapp.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:279)

08:49:22.519at com.caucho.server.webapp.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:108)

08:49:22.519at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:422)

08:49:22.519at com.sun.faces.application.ViewHandlerImpl.executePageToBuildView(ViewHandlerImpl.java:447)

08:49:22.519at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:116)

08:49:22.519at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)

08:49:22.519at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:248)

08:49:22.519at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)

08:49:22.519at javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)

08:49:22.519at com.caucho.server.dispatch.ServletFilterChain.doFilter(ServletFilterChain.java:103)

08:49:22.519at com.caucho.server.webapp.WebAppFilterChain.doFilter(WebAppFilterChain.java:167)

08:49:22.519at com.caucho.server.dispatch.ServletInvocation.service(ServletInvocation.java:226)

08:49:22.519at com.caucho.server.http.HttpRequest.handleRequest(HttpRequest.java:263)

08:49:22.519at com.caucho.server.port.TcpConnection.run(TcpConnection.java:477)

08:49:22.519at com.caucho.util.ThreadPool$Item.runTasks(ThreadPool.java:591)

08:49:22.519at com.caucho.util.ThreadPool$Item.run(ThreadPool.java:513)

08:49:22.519at java.lang.Thread.run(Thread.java:613)

I have added

<listener>

<listener-class>com.sun.faces.config.ConfigureListener</listener-class>

</listener>

to my web.xml.

TIA,

Sean

[2904 byte] By [swellinga] at [2007-11-26 18:26:46]
# 1
Based on the code, it would appear pageContext is null - this would imply an issue with the container.Have you tried deploying the same application to say GlassFish or Tomcat 6.0.9, or Jetty 6?
rlubkea at 2007-7-9 6:00:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

No, I haven't. The app in question here is "guessNumber" from the samples distributed with the kit, so I assume it does.

I know resin has a weird behavior in that it doesn't scan jar files for TLDs at app load time, but anecdotal accounts from the web indicate that adding the ConfigureListener to web.xml takes care of this. I can get JSF 1.1_01 to load in this container using the above technique.

Just to be clear, I added the jsf-api.jar and jsf-impl.jar files to my web application lib directory, and am using the deployment descriptors with only the above mentioned modification. Did I miss anything?

swellinga at 2007-7-9 6:00:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
It sounds like you've got your bases covered.I will have to grab resin and give this a go.
rlubkea at 2007-7-9 6:00:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
Did you ever resolve this issue? I am unable to run the JSF 1.2 sample apps on Resin 3.1...
erimaga at 2007-7-9 6:00:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5

I revisted this issue today and yesterday, and I'm not confident in this container at all.

Several red flags here.

1. They don't scan for listeners defined in TLDs and require that you A. add the

listener definition to your web.xml yourself, or enable a switch in their server configration.

2. Testing the new configuration code in the JSF 1.2 RI HEAD branch, where we use

DOM instead of commons-digester, I'm faced with another issue:

Caused by: java.lang.UnsupportedOperationException

[10:54:45.435] at com.caucho.xml.QDocument.getDocumentURI(QDocument.java:907)

Not only do they override the JAXP implementation included with SE5, but they

replace it with one that appears, like their web container, isn't compliant.

Message was edited by:

rlubke

rlubkea at 2007-7-9 6:00:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...