3 Replies Latest reply on Jan 30, 2006 8:57 AM by Mennen

    mysql + jboss + jbpm

    Mennen Newbie

      After the login page (cookie monster/bert/grover/ernie) of the starter's kit, I get the following error :

      javax.servlet.ServletException: Cannot get value for expression '#{homeBean.latestProcessDefinitions}'

      I managed to switch to a mysql database. I tested the connection and it seems to work fine.

      I know the jbpm login page can access the database because i added a new user, and it appeared within the list of users : cookie monster / bert / grover / ernie

      But when it starts to look for process definition in the database, it gives me this error.

      Any clues?ideas?

      Thanks in advance..

      Mennen
      _____________________________________________________________
      Here is the log of the error:
      2006-01-30 13:32:03,403 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/jbpm].[jsp]] Servlet.service() for servlet jsp threw exception
      javax.faces.el.EvaluationException: Cannot get value for expression '#{homeBean.latestProcessDefinitions}'
      at org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:399)
      at javax.faces.component.UIData.getValue(UIData.java:779)
      at javax.faces.component.UIData.createDataModel(UIData.java:545)
      at javax.faces.component.UIData.getDataModel(UIData.java:534)
      at javax.faces.component.UIData.getRowCount(UIData.java:103)
      at org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeInnerHtml(HtmlTableRendererBase.java:124)
      at org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:94)
      at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:319)
      at javax.faces.webapp.UIComponentTag.encodeChildren(UIComponentTag.java:343)
      at javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:251)
      at org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag(UIComponentBodyTagBase.java:55)
      at org.apache.jsp.home_jsp._jspx_meth_h_dataTable_1(org.apache.jsp.home_jsp:598)
      at org.apache.jsp.home_jsp._jspx_meth_f_view_0(org.apache.jsp.home_jsp:129)
      at org.apache.jsp.home_jsp._jspService(org.apache.jsp.home_jsp:76)
      at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672)
      at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)
      at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)
      at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
      at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:415)
      at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234)
      at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jbpm.webapp.filter.AuthenticationFilter.doFilter(AuthenticationFilter.java:25)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jbpm.webapp.filter.PersistenceFilter.doFilter(PersistenceFilter.java:28)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jbpm.webapp.filter.ContextFilter.doFilter(ContextFilter.java:19)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jbpm.webapp.filter.LogFilter.doFilter(LogFilter.java:38)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      at java.lang.Thread.run(Thread.java:534)
      Caused by: javax.faces.el.EvaluationException: org.jbpm.webapp.bean.HomeBean
      at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:78)
      at org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate(ELParserHelper.java:532)
      at org.apache.commons.el.ComplexValue.evaluate(ComplexValue.java:145)
      at org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:380)
      ... 60 more
      Caused by: javax.faces.el.EvaluationException: Bean: org.jbpm.webapp.bean.HomeBean, property: latestProcessDefinitions
      at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:404)
      at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:71)
      ... 63 more
      Caused by: java.lang.reflect.InvocationTargetException
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:400)
      ... 64 more
      Caused by: java.lang.NoClassDefFoundError: net/sf/ehcache/Element
      at net.sf.ehcache.Cache.put(Cache.java:317)
      at org.hibernate.cache.EhCache.put(EhCache.java:153)
      at org.hibernate.cache.NonstrictReadWriteCache.put(NonstrictReadWriteCache.java:68)
      at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:153)
      at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:842)
      at org.hibernate.loader.Loader.doQuery(Loader.java:717)
      at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:223)
      at org.hibernate.loader.Loader.loadEntity(Loader.java:1782)
      at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:93)
      at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:81)
      at org.hibernate.persister.entity.AbstractEntityPersister.load(AbstractEntityPersister.java:2729)
      at org.hibernate.event.def.DefaultLoadEventListener.loadFromDatasource(DefaultLoadEventListener.java:365)
      at org.hibernate.event.def.DefaultLoadEventListener.doLoad(DefaultLoadEventListener.java:346)
      at org.hibernate.event.def.DefaultLoadEventListener.load(DefaultLoadEventListener.java:123)
      at org.hibernate.event.def.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:161)
      at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:87)
      at org.hibernate.impl.SessionImpl.fireLoad(SessionImpl.java:809)
      at org.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:781)
      at org.hibernate.type.EntityType.resolveIdentifier(EntityType.java:266)
      at org.hibernate.type.EntityType.resolve(EntityType.java:303)
      at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:113)
      at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:842)
      at org.hibernate.loader.Loader.doQuery(Loader.java:717)
      at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:223)
      at org.hibernate.loader.Loader.doList(Loader.java:2147)
      at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2026)
      at org.hibernate.loader.Loader.list(Loader.java:2021)
      at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:369)
      at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:298)
      at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1020)
      at org.hibernate.impl.QueryImpl.list(QueryImpl.java:74)
      at org.jbpm.db.GraphSession.findLatestProcessDefinitions(GraphSession.java:112)
      at org.jbpm.webapp.bean.HomeBean.getLatestProcessDefinitions(HomeBean.java:31)

        • 1. Re: mysql + jboss + jbpm
          Rainer Alfoeldi Novice

           

          Caused by: java.lang.NoClassDefFoundError: net/sf/ehcache/Element


          It's all in the stacktrace. Check the jars in your classpath.

          Greetings

          • 2. Re: mysql + jboss + jbpm
            Mennen Newbie

            Thank you so much Rainer: I added the ehcache.jar and it worked!!

            For those who want to use MYSQL with jbpm, don't forget to add this line to your build.deploy.xml , under :



            It's because the folder hibernate contains a jar which is required by the application: ehcache-1.1.jar

            Mennen


            • 3. Re: mysql + jboss + jbpm
              Mennen Newbie

               

              "mennen" wrote:
              Thank you so much Rainer: I added the ehcache.jar and it worked!!

              For those who want to use MYSQL with jbpm, don't forget to add this line to your build.deploy.xml , under <copy todir="build/jbpm.war.dir/WEB-INF/lib">:

              <fileset dir="lib/hibernate" includes="*.jar" />

              It's because the folder hibernate contains a jar which is required by the application: ehcache-1.1.jar

              Mennen





              here is the code that did not appear :

              under < copy todir="build/jbpm.war.dir/WEB-INF/lib" >, add
              < fileset dir="lib/hibernate" includes="*.jar" / >