AnsweredAssumed Answered

Cannot get value ... '#{DocumentDetailsBean.versionHistory}'

Question asked by blega on Jun 13, 2008
Latest reply on Sep 13, 2008 by gatvars
Hello,

I'm using Alfresco 2.1 community edition and I ran into the following bug.

When I try to view the details of any document I have the permission to edit, I got
the following error :

javax.faces.FacesException: Cannot get value for expression '#{DocumentDetailsBean.versionHistory}'
caused by:
org.apache.jasper.JasperException: Cannot get value for expression '#{DocumentDetailsBean.versionHistory}'
caused by:
javax.faces.el.EvaluationException: Cannot get value for expression '#{DocumentDetailsBean.versionHistory}'
caused by:
javax.faces.el.EvaluationException: Exception getting value of property versionHistory of base of type : org.alfresco.web.bean.DocumentDetailsBean
caused by:
javax.faces.el.EvaluationException: Bean: org.alfresco.web.bean.DocumentDetailsBean, property: versionHistory
caused by:
java.lang.reflect.InvocationTargetException
caused by:
java.lang.NullPointerException


javax.faces.FacesException: Cannot get value for expression '#{DocumentDetailsBean.versionHistory}'
at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:425)
at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:211)
at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:132)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:140)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.alfresco.web.app.servlet.AuthenticationFilter.doFilter(AuthenticationFilter.java:81)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.apache.jasper.JasperException: Cannot get value for expression '#{DocumentDetailsBean.versionHistory}'
at org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:476)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:389)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:315)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:691)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:469)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:403)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:419)
… 21 more

It used to work fine, but for some reason, it doesn't work anymore.
I'm not sure right now what the reason is.

When I try to access a content I have no permission to edit, everything is ok.
When I log as an admin, everyting is ok.

I noticed that it used to be a similar issue (AR-135), but the issue is said to be fixed for long time (dec 2005), and
the stack strace is slightly different (the root cause is access denied for AR-135, my root cause is NPE).

If you have any idea what went wrong, don't hesitate.

B.

PS : being a Java+JCR developer, I'm not afraid to dig into the JCR nodes, JSF pages and so on ;)

Outcomes