Class MessageBeanListenerImpl

    • Method Detail

      • beforeMessageDelivery

        public void beforeMessageDelivery​(Method method,
                                          boolean txImported)
        Description copied from interface: MessageBeanListener
        Pre-delivery notification to the container. Any transaction initialization is peformed here. In addition, when this method returns, the current thread's context class loader will be set the message-bean's application class loader.
        Specified by:
        beforeMessageDelivery in interface MessageBeanListener
        Parameters:
        method - is the method that will be invoked during deliverMessage. It is used the container during transaction setup to lookup the appropriate transaction attribute.
        txImported - whether a transaction is being imported
      • deliverMessage

        public Object deliverMessage​(Object[] params)
                              throws Throwable
        Description copied from interface: MessageBeanListener
        Deliver a message to a message bean instance.
        Specified by:
        deliverMessage in interface MessageBeanListener
        Parameters:
        params - to use of the method invocation. Can be null or an 0-length array if there are 0 arguments.
        Throws:
        Throwable - This is either an application exception as thrown from the message bean instance or a jakarta.ejb.EJBException in the case that the bean throws a system exception. Note that exceptions are *always* propagated, regardless of transaction type.
      • afterMessageDelivery

        public void afterMessageDelivery()
        Description copied from interface: MessageBeanListener
        Post-delivery notification to the container. Container will perform any work required to commit/rollback a container-managed transaction. When this method returns, the thread's context class loader will be restored to the value it had when beforeMessageDelivery was called.
        Specified by:
        afterMessageDelivery in interface MessageBeanListener