Examples of handleException()


Examples of org.jibx.ws.soap.server.SoapFaultHandler.handleException()

    public void testSendFaultOnErrorWithoutStackTrace() throws Exception {
        SoapFaultHandler faultHandler = new SoapFaultHandler(false);
        try {
            throw new AssertionError("Dummy Assertion Error <99>");
        } catch (Throwable t) {
            faultHandler.handleException(t, m_processor, StubbedChannel.getOutConnection());
        }

        String expected = SoapMaker.envelope(SoapMaker.body("<SOAP:Fault>\n" + "<faultcode>SOAP:Server</faultcode>\n"
            + "<faultstring>Dummy Assertion Error &lt;99></faultstring>\n"
            + "</SOAP:Fault>\n"));
View Full Code Here

Examples of org.kitesdk.morphline.base.FaultTolerance.handleException()

 
  @Test
  public void testFaultTolerance() throws Exception {
    FaultTolerance tolerance = new FaultTolerance(true, false);
    tolerance = new FaultTolerance(true, true, IOException.class.getName());
    tolerance.handleException(new IOException(), new Record());
   
    tolerance = new FaultTolerance(true, true, IOException.class.getName());
    tolerance.handleException(new RuntimeException(), new Record());

    tolerance = new FaultTolerance(true, true, IOException.class.getName());
View Full Code Here

Examples of org.mule.api.MuleContext.handleException()

    @Test
    public void callSystemExceptionHandlerWhenExceptionIsMessagingException() throws Exception
    {
        MuleContext context = new DefaultMuleContextFactory().createMuleContext();
        context.setExceptionListener(mockSystemExceptionHandler);
        context.handleException(mockMessagingException);
        verify(mockSystemExceptionHandler, VerificationModeFactory.times(1)).handleException(mockMessagingException,null);
    }
   
    @Test
    public void getObjectStoreManager() throws Exception
View Full Code Here

Examples of org.mule.api.exception.MessagingExceptionHandler.handleException()

                        catch (MuleException e)
                        {
                            MessagingExceptionHandler exceptionListener = event.getFlowConstruct().getExceptionListener();
                            if (e instanceof MessagingException)
                            {
                                exceptionListener.handleException(e, event);
                            }
                            else
                            {
                                exceptionListener.handleException(new MessagingException(
                                    CoreMessages.eventProcessingFailedFor(getStageDescription()), event, e), event);
View Full Code Here

Examples of org.mule.api.exception.MessagingExceptionHandler.handleException()

                            {
                                exceptionListener.handleException(e, event);
                            }
                            else
                            {
                                exceptionListener.handleException(new MessagingException(
                                    CoreMessages.eventProcessingFailedFor(getStageDescription()), event, e), event);
                            }

                            // TODO Enable this to ensure Zero Message Loss
                            //      (although it will cause an infinite loop without some kind of redelivery policy)
View Full Code Here

Examples of org.mule.api.exception.MessagingExceptionHandler.handleException()

            catch (MuleException e)
            {
                MessagingExceptionHandler exceptionListener = event.getFlowConstruct().getExceptionListener();
                if (e instanceof MessagingException)
                {
                    exceptionListener.handleException(e, event);
                }
                else
                {
                    exceptionListener.handleException(new MessagingException(
                        CoreMessages.eventProcessingFailedFor(getStageDescription()), event, e), event);
View Full Code Here

Examples of org.mule.api.exception.MessagingExceptionHandler.handleException()

                {
                    exceptionListener.handleException(e, event);
                }
                else
                {
                    exceptionListener.handleException(new MessagingException(
                        CoreMessages.eventProcessingFailedFor(getStageDescription()), event, e), event);
                }
            }
        }
       
View Full Code Here

Examples of org.mule.exception.CatchMessagingExceptionStrategy.handleException()

            {
                CatchMessagingExceptionStrategy exceptionStrategy = new CatchMessagingExceptionStrategy();
                exceptionStrategy.setMuleContext(mockMuleContext);
                when(mockMuleContext.getNotificationManager()).thenReturn(mock(ServerNotificationManager.class));
                when(mockMuleContext.getRegistry()).thenReturn(mock(MuleRegistry.class));
                exceptionStrategy.handleException((Exception) invocationOnMock.getArguments()[0], (MuleEvent) invocationOnMock.getArguments()[1]);
                return mockResultEvent;
            }
        });
        return mockResultEvent;
    }
View Full Code Here

Examples of org.mule.exception.DefaultMessagingExceptionStrategy.handleException()

                }
                if (commitFilter != null)
                {
                    defaultMessagingExceptionStrategy.setCommitTxFilter(new WildcardFilter(commitFilter));
                }
                defaultMessagingExceptionStrategy.handleException((Exception) invocationOnMock.getArguments()[0], (MuleEvent) invocationOnMock.getArguments()[1]);
                return null;
            }
        });
    }
View Full Code Here

Examples of org.rssowl.core.util.LoggingSafeRunnable.handleException()

     */
    if (!isDisplayOperation && !isResourceOperation) {
      try {
        runnable.run();
      } catch (Exception e) {
        runnable.handleException(e);
      }
    } else
      SafeRunner.run(runnable);
  }

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.