Package org.apache.camel

Examples of org.apache.camel.CamelExecutionException


    public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) {
        if (e instanceof CamelExecutionException) {
            // don't double wrap
            return (CamelExecutionException)e;
        } else {
            return new CamelExecutionException("Exception occurred during execution", exchange, e);
        }
    }
View Full Code Here


    public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) {
        if (e instanceof CamelExecutionException) {
            // don't double wrap
            return (CamelExecutionException)e;
        } else {
            return new CamelExecutionException("Exception occurred during execution", exchange, e);
        }
    }
View Full Code Here

    public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) {
        if (e instanceof CamelExecutionException) {
            // don't double wrap
            return (CamelExecutionException)e;
        } else {
            return new CamelExecutionException("Exception occurred during execution", exchange, e);
        }
    }
View Full Code Here

        boolean threwException = false;
        try {
            response = template.requestBody("direct:unhandled", "Kaboom", String.class);
        } catch (Throwable e) {
            threwException = true;
            CamelExecutionException cee = assertIsInstanceOf(CamelExecutionException.class, e);
            Throwable cause = cee.getCause();
            assertIsInstanceOf(FlakyException.class, cause);
        }
        assertTrue(threwException);
        assertNull(response);
View Full Code Here

        boolean threwException = false;
        try {
            response = template.requestBodyAndHeader("direct:conditional", "Kaboom", "jedi", "This isn't the Exception you are looking for...", String.class);
        } catch (Throwable e) {
            threwException = true;
            CamelExecutionException cee = assertIsInstanceOf(CamelExecutionException.class, e);
            Throwable cause = cee.getCause();
            assertIsInstanceOf(FlakyException.class, cause);
        }
        assertTrue(threwException);
        assertNull(response);
View Full Code Here

        boolean threwException = false;
        try {
            response = template.requestBody("direct:unhandled", "Kaboom", String.class);
        } catch (Throwable e) {
            threwException = true;
            CamelExecutionException cee = assertIsInstanceOf(CamelExecutionException.class, e);
            Throwable cause = cee.getCause();
            assertIsInstanceOf(FlakyException.class, cause);
        }
        assertTrue(threwException);
        assertNull(response);
View Full Code Here

        boolean threwException = false;
        try {
            response = template.requestBodyAndHeader("direct:conditional", "Kaboom", "jedi", "This isn't the Exception you are looking for...", String.class);
        } catch (Throwable e) {
            threwException = true;
            CamelExecutionException cee = assertIsInstanceOf(CamelExecutionException.class, e);
            Throwable cause = cee.getCause();
            assertIsInstanceOf(FlakyException.class, cause);
        }
        assertTrue(threwException);
        assertNull(response);
View Full Code Here

    public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) {
        if (e instanceof CamelExecutionException) {
            // don't double wrap
            return (CamelExecutionException)e;
        } else {
            return new CamelExecutionException("Exception occurred during execution", exchange, e);
        }
    }
View Full Code Here

    public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) {
        if (e instanceof CamelExecutionException) {
            // don't double wrap
            return (CamelExecutionException)e;
        } else {
            return new CamelExecutionException("Exception occurred during execution", exchange, e);
        }
    }
View Full Code Here

    public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) {
        if (e instanceof CamelExecutionException) {
            // don't double wrap
            return (CamelExecutionException)e;
        } else {
            return new CamelExecutionException("Exception occurred during execution", exchange, e);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.camel.CamelExecutionException

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.