在同一个bean中使用EJB和JAXWS时,weblogic 12cR2令人烦恼的日志

时间:2016-03-06 15:28:59

标签: java weblogic jax-ws weblogic12c ejb-3.2

我有一个包含EJB项目(MyEJB)的Java EE项目(MyProject)我创建了一个会话bean(无状态),它也是我的Web服务类(ServiceAddTEST)。容器是weblogic 12.2.1。 一切顺利,但当我在weblogic的控制台中调用web服务时,显示以下消息:

<Mar 6, 2016 6:30:35 PM IRST> <Error> <Kernel> <BEA-000802> <ExecuteRequest failed
 java.lang.IllegalStateException: Context pushed was [(pId = 0, pName = DOMAIN, appId = MyProject, appName = MyProject, appVersion = null, mId = /ServiceAddTEST, compName = /ServiceAddTEST)], but context being popped is [(pId = 0, pName = DOMAIN, appId = MyProject, appName = MyProject, appVersion = null, mId = MyEJB, compName = ServiceAddTEST)].
java.lang.IllegalStateException: Context pushed was [(pId = 0, pName = DOMAIN, appId = MyProject, appName = MyProject, appVersion = null, mId = /ServiceAddTEST, compName = /ServiceAddTEST)], but context being popped is [(pId = 0, pName = DOMAIN, appId = MyProject, appName = MyProject, appVersion = null, mId = MyEJB, compName = ServiceAddTEST)]
        at weblogic.application.ComponentInvocationContextManagerImpl$4.validate(ComponentInvocationContextManagerImpl.java:256)
        at weblogic.application.ComponentInvocationContextManagerImpl$4.close(ComponentInvocationContextManagerImpl.java:231)
        at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352)
        at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:333)
        at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:54)
        Truncated. see log file for complete stacktrace
>

但是,Web服务运行正常。我想解决问题摆脱这个日志,我认为它可能会导致一些问题。 此外,日志文件中没有任何额外信息。以下是该类的代码:

@Stateless
@WebService
public class ServiceAddTEST {


    @WebMethod
    public int getCount(){
        return 20;
    }

关于环境:

  • Eclipse Mars
  • Java 1.8.0_71
  • Weblogic 12.2.1
  • EJB 3.2

2 个答案:

答案 0 :(得分:2)

该问题将在版本12.2.2.1.0中修复为claimed here

修改

通过应用patch 22648025(您需要Oracle支持帐户才能获得)来修复

答案 1 :(得分:0)

我经常搜索这个问题,最后我发现它可能是weblogic12cR2的一个错误,因为这个场景非常简单。见link。 我决定降级weblogic,现在我正在使用Weblogic 12.1.2,它运行正常。