Package org.apache.camel.component.seda

Examples of org.apache.camel.component.seda.SedaEndpoint


    protected static Map<String, BlockingQueue> queues = new HashMap<String, BlockingQueue>();

    @Override
    protected Endpoint createEndpoint(String uri, String remaining, Map parameters) throws Exception {
        BlockingQueue<Exchange> blockingQueue = getBlockingQueue(uri);
        return new SedaEndpoint(uri, this, blockingQueue);
    }
View Full Code Here


        template.sendBody("seda:beer", "A");

        // wait up till 5 sec as it should be routed completed now
        assertEquals(true, notify.matches(5, TimeUnit.SECONDS));

        SedaEndpoint confirm = context.getEndpoint("seda:done", SedaEndpoint.class);
        assertEquals(1, confirm.getExchanges().size());
    }
View Full Code Here

    protected Endpoint createEndpoint(String uri, String remaining, Map<String, Object> parameters) throws Exception {
        if (ENDPOINTS.containsKey(uri)) {
            return ENDPOINTS.get(uri);
        }

        SedaEndpoint answer = (SedaEndpoint) super.createEndpoint(uri, remaining, parameters);

        ENDPOINTS.put(uri, answer);
        return answer;
    }
View Full Code Here

            public void configure() throws Exception {
                // put a message pre-early on the seda queue, to trigger the route, which
                // then would add a 2nd route during CamelContext startup. This is a test
                // to ensure the foo route is not started too soon, and thus adding the 2nd
                // route works as expected
                SedaEndpoint seda = context.getEndpoint("seda:start", SedaEndpoint.class);
                seda.getQueue().put(new DefaultExchange(context));

                from("seda:start").routeId("foo")
                        .process(new Processor() {
                            @Override
                            public void process(Exchange exchange) throws Exception {
View Full Code Here

TOP

Related Classes of org.apache.camel.component.seda.SedaEndpoint

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.