Examples of ExceptionPayload


Examples of org.mule.api.ExceptionPayload

        MuleClient client = new MuleClient(muleContext);

        MuleMessage reply = client.send("vm://echo", "An unsigned message", null);
       
        assertNotNull(reply.getExceptionPayload());
        ExceptionPayload excPayload = reply.getExceptionPayload();
        assertEquals(MESSAGE_EXCEPTION, excPayload.getMessage());
    }
View Full Code Here

Examples of org.mule.api.ExceptionPayload

        public MuleEvent process(MuleEvent event) throws MuleException
        {
            final MuleEvent nextResult = super.processNext(event);

            final ExceptionPayload nextResultMessageExceptionPayload = getExceptionPayload(nextResult);

            if (nextResultMessageExceptionPayload != null)
            {
                return errorExpressionTransformer.process(event);
            }
View Full Code Here

Examples of org.mule.api.ExceptionPayload

            try
            {
                final MuleEvent nextResult = super.processNext(event);

                final ExceptionPayload nextResultMessageExceptionPayload = getExceptionPayload(nextResult);

                if (nextResultMessageExceptionPayload != null)
                {
                    result.getMessage().setExceptionPayload(nextResultMessageExceptionPayload);
                }
View Full Code Here

Examples of org.mule.api.ExceptionPayload

            if (faultMsg != null)
            {
                Exception ex = faultMsg.getContent(Exception.class);
                if (ex != null)
                {
                    ExceptionPayload exceptionPayload = new DefaultExceptionPayload(ex);
                    event.getMessage().setExceptionPayload(exceptionPayload);
                    muleResMsg.setOutboundProperty(HttpConnector.HTTP_STATUS_PROPERTY, 500);
                }
            }
View Full Code Here

Examples of org.mule.api.ExceptionPayload

            try
            {
                logger.warn("Failed to read message: " + readingException);

                MuleMessage msg = new DefaultMuleMessage(NullPayload.getInstance(), connector.getMuleContext());
                ExceptionPayload exceptionPayload = new DefaultExceptionPayload(readingException);
                msg.setExceptionPayload(exceptionPayload);
                List msgList = new ArrayList(1);
                msgList.add(msg);

                handleResults(msgList);
View Full Code Here

Examples of org.mule.api.ExceptionPayload

        if (message == null)
        {
            return false;
        }

        final ExceptionPayload exceptionPayload = message.getExceptionPayload();
        if (exceptionPayload != null)
        {
            logger.info("Failure returned, will try next endpoint. Exception payload is: " + exceptionPayload);
            return true;
        }
View Full Code Here

Examples of org.mule.api.ExceptionPayload

            if (faultMsg != null)
            {
                Exception ex = faultMsg.getContent(Exception.class);
                if (ex != null)
                {
                    ExceptionPayload exceptionPayload = new DefaultExceptionPayload(new Exception(""));
                    ctx.getMessage().setExceptionPayload(exceptionPayload);
                }
            }
            else
              //PATCH 2 START
View Full Code Here

Examples of org.mule.api.ExceptionPayload

            if (faultMsg != null)
            {
                Exception ex = faultMsg.getContent(Exception.class);
                if (ex != null)
                {
                    ExceptionPayload exceptionPayload = new DefaultExceptionPayload(ex);
                    event.getMessage().setExceptionPayload(exceptionPayload);
                    muleResMsg.setOutboundProperty(HttpConnector.HTTP_STATUS_PROPERTY, 500);
                }
            }
View Full Code Here

Examples of org.mule.api.ExceptionPayload

            {
                return message.getEncoding();
            }
            else if (expression.equals("exception"))
            {
                ExceptionPayload ep = message.getExceptionPayload();
                if (ep != null)
                {
                    return ep.getException();
                }
                return null;
            }
            else
            {
View Full Code Here

Examples of org.mule.api.ExceptionPayload

    public static class ExceptionSaver implements MessageProcessor
    {
        @Override
        public MuleEvent process(MuleEvent event) throws MuleException
        {
            ExceptionPayload exceptionPayload = event.getMessage().getExceptionPayload();
            exceptionFromFlow = exceptionPayload.getException();

            return null;
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.