This week's book giveaway is in the Android forum.
We're giving away four copies of Head First Android and have Dawn & David Griffiths on-line!
See this thread for details.
The moose likes JSF and the fly likes Trinidad components - first time user Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Trinidad components - first time user" Watch "Trinidad components - first time user" New topic

Trinidad components - first time user

Ravi Chilakapati

Joined: Apr 20, 2010
Posts: 10
I currently need to have a project with both trinidad and ajax4jsf. I will give my web.xml and faces-config.xml below. Also, I have the basic trinidad-config.xml. I am getting this error when I try to access a page which contains no trinidad components but does contain rich faces components. I am also getting the same error if I have trinidad components.

I have trinidad jars along with jsf-api.jar, jsf-impl.jar and jsf-facelets.jar.

java.lang.IllegalStateException: No RenderingContext
at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(
at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(
at org.apache.myfaces.trinidad.component.UIXComponentBase.__encodeRecursive(
at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeAll(
at javax.faces.render.Renderer.encodeChildren(
at javax.faces.component.UIComponentBase.encodeChildren(
at javax.faces.component.UIComponent.encodeAll(
at javax.faces.component.UIComponent.encodeAll(
at com.sun.facelets.FaceletViewHandler.renderView(
at org.ajax4jsf.application.ViewHandlerWrapper.renderView(
at org.ajax4jsf.application.AjaxViewHandler.renderView(
at com.sun.faces.lifecycle.RenderResponsePhase.execute(
at com.sun.faces.lifecycle.LifecycleImpl.phase(
at com.sun.faces.lifecycle.LifecycleImpl.render(
at javax.faces.webapp.FacesServlet.service(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(
at org.ajax4jsf.webapp.BaseFilter.handleRequest(
at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(
at org.ajax4jsf.webapp.BaseFilter.doFilter(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.apache.catalina.core.ApplicationDispatcher.invoke(
at org.apache.catalina.core.ApplicationDispatcher.processRequest(
at org.apache.catalina.core.ApplicationDispatcher.doForward(
at org.apache.catalina.core.ApplicationDispatcher.forward(
at org.apache.jasper.runtime.PageContextImpl.doForward(
at org.apache.jasper.runtime.PageContextImpl.forward(
at org.apache.jsp.index_jsp._jspService(
at org.apache.jasper.runtime.HttpJspBase.service(
at javax.servlet.http.HttpServlet.service(
at org.apache.jasper.servlet.JspServletWrapper.service(
at org.apache.jasper.servlet.JspServlet.serviceJspFile(
at org.apache.jasper.servlet.JspServlet.service(
at javax.servlet.http.HttpServlet.service(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.apache.catalina.core.StandardWrapperValve.invoke(
at org.apache.catalina.core.StandardContextValve.invoke(
at org.apache.catalina.core.StandardHostValve.invoke(
at org.apache.catalina.valves.ErrorReportValve.invoke(
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(
at org.apache.catalina.authenticator.SingleSignOn.invoke(
at org.apache.catalina.core.StandardEngineValve.invoke(
at org.apache.catalina.connector.CoyoteAdapter.service(
at org.apache.coyote.http11.Http11AprProcessor.process(
at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(
at Source)

My Jboss console shows this followed by the same stack trace as above:

12:29:19,370 ERROR [STDERR] Jan 19, 2011 12:29:19 PM org.apache.myfaces.trinidadinternal.renderkit.core.CoreRenderKit createResponseWriter
SEVERE: No RenderingContext has been created.
12:29:20,120 ERROR [STDERR] Jan 19, 2011 12:29:20 PM com.sun.facelets.FaceletViewHandler handleRenderException
SEVERE: Error Rendering View[/pages/common/Log-in.xhtml]

My web.xml

My faces-config.xml

Another question: Will a server side state saving have a huge impact of performance and scalability? I read that Trinidad recommends client side state saving and the advantages and disadvantages of both the methods, but I want to know if any one has some real-world scenarios?

Any inputs will be greatly appreciated!

Ravi Chilakapati

Joined: Apr 20, 2010
Posts: 10
OK.. Looks like I resolved this.. My faces-config.xml file had the following entry twice - one commented and one uncommented. And apparently, Trinidad crashes with that setting.

Today's lesson: Check your files for duplicate entries like this. Don't stop searching because you found a commented out entry.


Ravi Kiran.
I agree. Here's the link:
subject: Trinidad components - first time user
It's not a secret anymore!