鲍国钰的博客
谋事在人成事在天
posts - 5,  comments - 6,  trackbacks - 0
环境
JDK1.5.0_06、Weblogic9.2、Shark2.4-8-25、Windows2008
项目在使用的时候,登录正常,但是走工作流程的时候就抛出异常,
java.lang.NoSuchMethodError: org.mozilla.javascript.Context.toType(Ljava/lang/Ob
ject;Ljava
/lang/Class;)Ljava/lang/Object;
        at org.enhydra.shark.scripting.JavaScriptEvaluator.evaluateExpression(Ja
vaScriptEvaluator.java:
84)
        at org.enhydra.shark.scripting.JavaScriptEvaluator.evaluateCondition(Jav
aScriptEvaluator.java:
44)
        at org.enhydra.shark.WfProcessImpl.getTransFrom(WfProcessImpl.java:
1334)

        at org.enhydra.shark.WfProcessImpl.queueNext(WfProcessImpl.java:
1057)
        at org.enhydra.shark.WfProcessImpl.run(WfProcessImpl.java:
751)
        at org.enhydra.shark.WfProcessImpl.activity_complete(WfProcessImpl.java:
972)
        at org.enhydra.shark.WfActivityImpl.finish(WfActivityImpl.java:
443)
        at org.enhydra.shark.WfActivityImpl.complete(WfActivityImpl.java:
368)
        at org.enhydra.shark.SharkUtilities.changeActivityState(SharkUtilities.j
ava:
1979)
        at org.enhydra.shark.WfActivityWrapper.change_state(WfActivityWrapper.ja
va:
384)
        at com.code.SharkWfUtils.setActivity(SharkWfUtils.java:
430)
        at com.servlet.wfServlet.doGet(wfServlet.java:
459)
        at com.servlet.wfServlet.doPost(wfServlet.java:
521)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
763)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
856)
        at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run
(StubSecurityHelper.java:
225)
        at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecuri
tyHelper.java:
127)
        at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
a:
283)
        at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
a:
175)
        at weblogic.servlet.internal.WebAppServletContext$ServletInvocationActio
n.run(WebAppServletContext.java:
3214)
        at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Authenticate
dSubject.java:
321)
        at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:
121)
        at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppS
ervletContext.java:
1983)
        at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletC
ontext.java:
1890)
        at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.j
ava:
1344)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:
209)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:
181)
org.enhydra.shark.api.RootException: Result cannot be evaluated
        at org.enhydra.shark.scripting.JavaScriptEvaluator.evaluateExpression(Ja
vaScriptEvaluator.java:
107)
        at org.enhydra.shark.scripting.JavaScriptEvaluator.evaluateCondition(Jav
aScriptEvaluator.java:
44)
        at org.enhydra.shark.WfProcessImpl.getTransFrom(WfProcessImpl.java:
1334)

        at org.enhydra.shark.WfProcessImpl.queueNext(WfProcessImpl.java:
1057)
        at org.enhydra.shark.WfProcessImpl.run(WfProcessImpl.java:
751)
        at org.enhydra.shark.WfProcessImpl.activity_complete(WfProcessImpl.java:
972)
        at org.enhydra.shark.WfActivityImpl.finish(WfActivityImpl.java:
443)
        at org.enhydra.shark.WfActivityImpl.complete(WfActivityImpl.java:
368)
        at org.enhydra.shark.SharkUtilities.changeActivityState(SharkUtilities.j
ava:
1979)
        at org.enhydra.shark.WfActivityWrapper.change_state(WfActivityWrapper.ja
va:
384)
        at com.code.SharkWfUtils.setActivity(SharkWfUtils.java:
430)
        at com.servlet.wfServlet.doGet(wfServlet.java:
459)
        at com.servlet.wfServlet.doPost(wfServlet.java:
521)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
763)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
856)
        at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run
(StubSecurityHelper.java:
225)
        at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecuri
tyHelper.java:
127)
        at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
a:
283)
        at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
a:
175)
        at weblogic.servlet.internal.WebAppServletContext$ServletInvocationActio
n.run(WebAppServletContext.java:
3214)
        at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Authenticate
dSubject.java:
321)
        at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:
121)
        at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppS
ervletContext.java:
1983)
        at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletC
ontext.java:
1890)
        at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.j
ava:
1344)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:
209)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:
181)
Caused by: java.lang.NoSuchMethodError: org.mozilla.javascript.Context.toType(Lj
ava
/lang/Object;Ljava/lang/Class;)Ljava/lang/Object;
        at org.enhydra.shark.scripting.JavaScriptEvaluator.evaluateExpression(Ja
vaScriptEvaluator.java:
84)
         
26 more

解压缩C:\bea\weblogic92\server\lib目录下的weblogic.jar发现项目中使用的js.jar包名与weblogic.jar下的包名冲突,比较其中的class文件发现数量不同,
经过反编译比较发现,具体的方法和变量也多少有所不同。

解决方式,将js.jar下的class文件覆盖到weblogic.jar下的对应包下面,然后再次打包成jar包,放到C:\bea\weblogic92\server\lib目录下,重新启动weblogic对应的域。

问题解决了。

欢迎交流。
posted on 2011-01-14 16:15 鲍国钰 阅读(2771) 评论(0)  编辑  收藏

只有注册用户登录后才能发表评论。


网站导航:
 

<2011年1月>
2627282930311
2345678
9101112131415
16171819202122
23242526272829
303112345

常用链接

留言簿

随笔档案

文章分类

搜索

  •  

最新评论

阅读排行榜

评论排行榜