Package org.mule.construct

Examples of org.mule.construct.Bridge


public class BridgeBuilderTestCase extends AbstractMuleTestCase
{
    public void testFullConfiguration() throws Exception
    {
        Bridge bridge = new BridgeBuilder().name("test-bridge-full")
            .inboundAddress("test://foo.in")
            .transformers(new StringAppendTransformer("bar"))
            .responseTransformers(new ObjectToByteArray(), new GZipCompressTransformer())
            .outboundAddress("test://foo.out")
            .exchangePattern(MessageExchangePattern.REQUEST_RESPONSE)
            .transacted(false)
            .exceptionStrategy(new DefaultMessagingExceptionStrategy(muleContext, true))
            .build(muleContext);

        assertEquals("test-bridge-full", bridge.getName());
    }
View Full Code Here


        assertEquals("test-bridge-full", bridge.getName());
    }

    public void testTransacted() throws Exception
    {
        Bridge bridge = new BridgeBuilder().name("test-bridge-transacted")
            .inboundAddress("test://foo.in")
            .outboundAddress("test2://foo.out")
            .transacted(true)
            .build(muleContext);

        assertEquals("test-bridge-transacted", bridge.getName());
    }
View Full Code Here

        if (transacted)
        {
            setTransactionFactoriesIfNeeded(inboundEndpoint, outboundEndpoint);
        }

        return new Bridge(name, muleContext, inboundEndpoint, outboundEndpoint, transformers,
            responseTransformers, exchangePattern, transacted);
    }
View Full Code Here

        if (transacted)
        {
            setTransactionFactoriesIfNeeded(inboundEndpoint, outboundEndpoint);
        }

        return new Bridge(name, muleContext, inboundEndpoint, outboundEndpoint, transformers,
            responseTransformers, exchangePattern, transacted);
    }
View Full Code Here

public class BridgeBuilderTestCase extends AbstractMuleContextTestCase
{
    @Test
    public void testFullConfiguration() throws Exception
    {
        Bridge bridge = new BridgeBuilder().name("test-bridge-full")
            .inboundAddress("test://foo.in")
            .transformers(new StringAppendTransformer("bar"))
            .responseTransformers(new ObjectToByteArray(), new GZipCompressTransformer())
            .outboundAddress("test://foo.out")
            .exchangePattern(MessageExchangePattern.REQUEST_RESPONSE)
            .transacted(false)
            .exceptionStrategy(new DefaultMessagingExceptionStrategy(muleContext))
            .build(muleContext);

        assertEquals("test-bridge-full", bridge.getName());
    }
View Full Code Here

    }

    @Test
    public void testTransacted() throws Exception
    {
        Bridge bridge = new BridgeBuilder().name("test-bridge-transacted")
            .inboundAddress("test://foo.in")
            .outboundAddress("test2://foo.out")
            .transacted(true)
            .build(muleContext);

        assertEquals("test-bridge-transacted", bridge.getName());
    }
View Full Code Here

TOP

Related Classes of org.mule.construct.Bridge

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.