Package org.mule.api.exception

Examples of org.mule.api.exception.RollbackSourceCallback


                worker.processMessages();
            }
            catch (Exception e)
            {
                // Use this rollback method in case a transaction has not been configured on the endpoint.
                RollbackSourceCallback rollbackMethod = new RollbackSourceCallback()
                {
                    @Override
                    public void rollback()
                    {
                        recoverSession();
                    }
                };

                if (e instanceof MessagingException)
                {
                    MessagingException messagingException = (MessagingException) e;
                    if (!messagingException.getEvent().isTransacted() && messagingException.causedRollback())
                    {
                        rollbackMethod.rollback();
                    }
                }
                else
                {
                    getEndpoint().getMuleContext().getExceptionListener().handleException(e, rollbackMethod);
View Full Code Here

TOP

Related Classes of org.mule.api.exception.RollbackSourceCallback

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.