关于jbpm4.4的el的问题 de.odysseus.el.ExpressionFactoryImpl找不到问题

时间:2022-09-08 20:23:35

第一份工作中遇到这个问题,项目中使用到工作流框架activiti 调试发现报错


控制台报de.odysseus.el.ExpressionFactoryImpl找不到问题
在网上查找后发现JBMP在iteye开了个官方群组回答了这个问题,给出了解决办法

ckxtl的博客: 	
ckxtl 2010-09-21

还是菜鸟问题.
项目中如果加入了juel-api.jar,juel-impl.jar,(juel-engine.jar)在打开jsp页面的时候报这个错误.javax.servlet.ServletException: java.lang.LinkageError: loader constraint violation: when resolving interface method "javax.servlet.jsp.JspApplicationContext.getExpressionFactory()Ljavax/el/ExpressionFactory;" the class loader (instance of org/apache/jasper/servlet/JasperLoader) of the current class, org/apache/jsp/index_jsp, and the class loader (instance of org/jboss/classloader/spi/base/BaseClassLoader) for resolved class, javax/servlet/jsp/JspApplicationContext, have different Class objects for the type javax/el/ExpressionFactory used in the signature
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:257)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

root cause

java.lang.LinkageError: loader constraint violation: when resolving interface method "javax.servlet.jsp.JspApplicationContext.getExpressionFactory()Ljavax/el/ExpressionFactory;" the class loader (instance of org/apache/jasper/servlet/JasperLoader) of the current class, org/apache/jsp/index_jsp, and the class loader (instance of org/jboss/classloader/spi/base/BaseClassLoader) for resolved class, javax/servlet/jsp/JspApplicationContext, have different Class objects for the type javax/el/ExpressionFactory used in the signature
org.apache.jsp.index_jsp._jspInit(index_jsp.java:22)
org.apache.jasper.runtime.HttpJspBase.init(HttpJspBase.java:52)
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:154)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

如果不加入这三个jar,在打开jsp的时候不会报错,但是在新流程发布的时候报下面这个错误.

org.apache.jasper.JasperException: org.jbpm.api.JbpmException:
error: parsing exception: expression factory class not found : javax.el.ELException: expression factory class not found
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:515)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:411)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

root cause

org.jbpm.api.JbpmException:
error: parsing exception: expression factory class not found : javax.el.ELException: expression factory class not found
org.jbpm.pvm.internal.xml.ProblemList.getJbpmException(ProblemList.java:175)
org.jbpm.pvm.internal.xml.ProblemList.getJbpmException(ProblemList.java:141)
org.jbpm.pvm.internal.repository.DeployerManager.deploy(DeployerManager.java:50)
org.jbpm.pvm.internal.repository.RepositorySessionImpl.deploy(RepositorySessionImpl.java:62)
org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:47)
org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:33)
org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42)
org.jbpm.pvm.internal.tx.SpringCommandCallback.doInTransaction(SpringCommandCallback.java:45)
org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:130)
org.jbpm.pvm.internal.tx.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:49)
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.executeInNewEnvironment(EnvironmentInterceptor.java:53)
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.execute(EnvironmentInterceptor.java:40)
org.jbpm.pvm.internal.svc.RetryInterceptor.execute(RetryInterceptor.java:56)
org.jbpm.pvm.internal.repository.DeploymentImpl.deploy(DeploymentImpl.java:90)
org.apache.jsp.holiday.deploy_005fzip_jsp._jspService(deploy_005fzip_jsp.java:70)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:369)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

root cause

javax.el.ELException: expression factory class not found
org.jbpm.pvm.internal.el.FactoryFinder.newInstance(FactoryFinder.java:63)
org.jbpm.pvm.internal.el.FactoryFinder.find(FactoryFinder.java:118)
org.jbpm.pvm.internal.el.JbpmElFactoryImpl.createExpressionFactory(JbpmElFactoryImpl.java:111)
org.jbpm.pvm.internal.el.Expression.initExpressionObjects(Expression.java:100)
org.jbpm.pvm.internal.el.Expression.create(Expression.java:67)
org.jbpm.jpdl.internal.xml.JpdlParser.parseAssignmentAttributes(JpdlParser.java:528)
org.jbpm.jpdl.internal.xml.JpdlParser.parseTaskDefinition(JpdlParser.java:593)
org.jbpm.jpdl.internal.activity.TaskBinding.parseJpdl(TaskBinding.java:45)
org.jbpm.jpdl.internal.activity.JpdlBinding.parse(JpdlBinding.java:45)
org.jbpm.jpdl.internal.xml.JpdlParser.parseActivities(JpdlParser.java:320)
org.jbpm.jpdl.internal.xml.JpdlParser.parseDocumentElement(JpdlParser.java:248)
org.jbpm.pvm.internal.xml.Parser.parseDocument(Parser.java:480)
org.jbpm.pvm.internal.xml.Parser.execute(Parser.java:432)
org.jbpm.pvm.internal.xml.Parse.execute(Parse.java:158)
org.jbpm.pvm.internal.repository.ProcessDeployer.deploy(ProcessDeployer.java:68)
org.jbpm.pvm.internal.repository.DeployerManager.deploy(DeployerManager.java:46)
org.jbpm.pvm.internal.repository.RepositorySessionImpl.deploy(RepositorySessionImpl.java:62)
org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:47)
org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:33)
org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42)
org.jbpm.pvm.internal.tx.SpringCommandCallback.doInTransaction(SpringCommandCallback.java:45)
org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:130)
org.jbpm.pvm.internal.tx.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:49)
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.executeInNewEnvironment(EnvironmentInterceptor.java:53)
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.execute(EnvironmentInterceptor.java:40)
org.jbpm.pvm.internal.svc.RetryInterceptor.execute(RetryInterceptor.java:56)
org.jbpm.pvm.internal.repository.DeploymentImpl.deploy(DeploymentImpl.java:90)
org.apache.jsp.holiday.deploy_005fzip_jsp._jspService(deploy_005fzip_jsp.java:70)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:369)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

root cause

java.lang.ClassNotFoundException: de.odysseus.el.ExpressionFactoryImpl
java.net.URLClassLoader$1.run(Unknown Source)
java.security.AccessController.doPrivileged(Native Method)
java.net.URLClassLoader.findClass(Unknown Source)
java.lang.ClassLoader.loadClass(Unknown Source)
java.lang.ClassLoader.loadClass(Unknown Source)
org.jbpm.pvm.internal.el.FactoryFinder.newInstance(FactoryFinder.java:60)
org.jbpm.pvm.internal.el.FactoryFinder.find(FactoryFinder.java:118)
org.jbpm.pvm.internal.el.JbpmElFactoryImpl.createExpressionFactory(JbpmElFactoryImpl.java:111)
org.jbpm.pvm.internal.el.Expression.initExpressionObjects(Expression.java:100)
org.jbpm.pvm.internal.el.Expression.create(Expression.java:67)
org.jbpm.jpdl.internal.xml.JpdlParser.parseAssignmentAttributes(JpdlParser.java:528)
org.jbpm.jpdl.internal.xml.JpdlParser.parseTaskDefinition(JpdlParser.java:593)
org.jbpm.jpdl.internal.activity.TaskBinding.parseJpdl(TaskBinding.java:45)
org.jbpm.jpdl.internal.activity.JpdlBinding.parse(JpdlBinding.java:45)
org.jbpm.jpdl.internal.xml.JpdlParser.parseActivities(JpdlParser.java:320)
org.jbpm.jpdl.internal.xml.JpdlParser.parseDocumentElement(JpdlParser.java:248)
org.jbpm.pvm.internal.xml.Parser.parseDocument(Parser.java:480)
org.jbpm.pvm.internal.xml.Parser.execute(Parser.java:432)
org.jbpm.pvm.internal.xml.Parse.execute(Parse.java:158)
org.jbpm.pvm.internal.repository.ProcessDeployer.deploy(ProcessDeployer.java:68)
org.jbpm.pvm.internal.repository.DeployerManager.deploy(DeployerManager.java:46)
org.jbpm.pvm.internal.repository.RepositorySessionImpl.deploy(RepositorySessionImpl.java:62)
org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:47)
org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:33)
org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42)
org.jbpm.pvm.internal.tx.SpringCommandCallback.doInTransaction(SpringCommandCallback.java:45)
org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:130)
org.jbpm.pvm.internal.tx.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:49)
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.executeInNewEnvironment(EnvironmentInterceptor.java:53)
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.execute(EnvironmentInterceptor.java:40)
org.jbpm.pvm.internal.svc.RetryInterceptor.execute(RetryInterceptor.java:56)
org.jbpm.pvm.internal.repository.DeploymentImpl.deploy(DeploymentImpl.java:90)
org.apache.jsp.holiday.deploy_005fzip_jsp._jspService(deploy_005fzip_jsp.java:70)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:369)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter

昨天晚上查这个问题查到两点多,在网上找到这么一句话"所有与el表达式相关的部分都替换为新加的org.jbpm.pvm.internal.el.Expression。"请教各位,如何将el表达式相关的部分替换为org.jbpm.pvm.internal.el.Expression

xznsoft的博客: xznsoft
xznsoft 2010-09-21
删除juel-api.jar包即可,因为它和tomcat的lib目录下el-api.jar冲突
ckxtl的博客:
ckxtl 2010-09-21
我使用的是jboss5.1,不是tomcat
我的环境:
JDK 1.6
JBOSS 5.1
SPRING3.04
JBPM4.4
我项目引用的包如下:
activation.jar
antlr.jar
cglib.jar
commons-collections.jar
commons-logging.jar
dom4j.jar
dwr.jar
hibernate-core.jar
jbpm.rar
jbpm-bpmn.rar
jbpm-console-form-plugin.jar
jbpm-console-graphView-plugin.jar
jbpm-console-integration.jar
jbpm-console-reports.jar
jbpm-db.jar
jbpm-examples-tests.jar
jbpm-jboss.jar
jbpm-test-db-tests.jar
jta.jar
junit.jar
livetribe-jsr223.jar
log4j.jar
mail.rar
mysql-connector-java.jar
org.springframework.aop-3.0.4.RELEASE.jar
org.springframework.asm-3.0.4.RELEASE.jar
org.springframework.aspects-3.0.4.RELEASE.jar
org.springframework.beans-3.0.4.RELEASE.jar
org.springframework.context.support-3.0.4.RELEASE.jar
org.springframework.context-3.0.4.RELEASE.jar
org.springframework.core-3.0.4.RELEASE.jar
org.springframework.expression-3.0.4.RELEASE.jar
org.springframework.instrument-3.0.4.RELEASE.jar
org.springframework.jdbc-3.0.4.RELEASE.jar
org.springframework.jms-3.0.4.RELEASE.jar
org.springframework.orm-3.0.4.RELEASE.jar
org.springframework.oxm-3.0.4.RELEASE.jar
org.springframework.test-3.0.4.RELEASE.jar
org.springframework.transaction-3.0.4.RELEASE.jar
org.springframework.web.portlet-3.0.4.RELEASE.jar
org.springframework.web.servlet-3.0.4.RELEASE.jar
org.springframework.web.struts-3.0.4.RELEASE.jar
org.springframework.web-3.0.4.RELEASE.jar
xznsoft的博客: xznsoft
xznsoft 2010-09-21
jboss不熟,我看了下jboss一样包含el-api.jar,你在项目的lib中删除juel-api.jar库juel-impl.jar和juel-engine.jar保留应该就没有问题了
青雉的博客: 青雉
青雉 2010-09-23
我也遇到同样问题。你解决了吗?
xyz20003的博客: 镜花水月
xyz20003 2010-09-23
tomcat5下,juel-api.jar,juel-impl.jar,(juel-engine.jar)三个包全加
tomcat6下,只加juel-impl.jar和juel-engine.jar
青雉的博客: 青雉
青雉 2010-09-23
好了。
我是把juel-api.jar,juel-impl.jar,juel-engine.jar替换了。tomcat6下的el-api.jar
不过这样需要实施的时候特殊说明了。
luweisouma的博客:
luweisouma 2010-10-29
我使用的是tomcat6,jdk1.6,将lib下的juel-api.jar删除即可。
我看juel-api.jar和tomcat下的el-api.jar的内容是一样的,因为有冲突所以报错。
imp860124的博客: 懒到变成虫
imp860124 2011-01-24
我用的也是Tomcat6和jdk1.6,报这个错后按网上的说法把jbpm4.4 lib下面的juel-api.jar,juel-impl.jar,juel-engine.jar都拷进工程,还是报错,在这里找到解决方案啊。