Uploaded image for project: 'Weld'
  1. Weld
  2. WELD-1701

@PreDestroy method throw WELD-000019 exception

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • 2.2.3.Final
    • 2.2.2.Final
    • Conversations, Events
    • None

      My Conversation Scoped Bean has a @PreDestroy method, this method try to check another conversation scoped bean.
      This works fine in normal case, but when the session timeout. it close the all the scope context, it will cause the method error:

      java.lang.IllegalStateException: WELD-000333: Must call associate() before calling activate()
      at org.jboss.weld.servlet.ConversationContextActivator.determineConversationId(ConversationContextActivator.java:180)
      at org.jboss.weld.context.http.LazyHttpConversationContextImpl.checkContextInitialized(LazyHttpConversationContextImpl.java:93)
      at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:74)
      at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:114)
      at org.jboss.weld.context.PassivatingContextWrapper$AbstractPassivatingContextWrapper.get(PassivatingContextWrapper.java:70)
      at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:81)
      at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:78)
      at com.cgi.horizon.financial.model.HorizonFinancialContext$Proxy$_$$_WeldClientProxy.getCheques(Unknown Source)
      at com.cgi.horizon.financial.service.HorizonChequeService.release(HorizonChequeService.java:199)

      And WELD swallowed the real exception, spit out a WELD-000019 error.
      Is this designed behavior or a bug?

            mkouba@redhat.com Martin Kouba
            wangliyu_jira Wang Liyu (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: