Package org.apache.camel.impl

Examples of org.apache.camel.impl.DefaultCamelContext.stop()


        CamelContext context = new DefaultCamelContext();
        context.addComponent("properties", new PropertiesComponent("sampleconfig.properties"));
        context.addRoutes(new OrderRouteBuilder());
        context.start();
        System.in.read();
        context.stop();
    }
   
    public static void main(String[] args) throws Exception {
        new Starter().run();
    }
View Full Code Here


        addJmsComponent(context);
        context.setTracing(true);
        context.addRoutes(new Jpa2JmsRoute());
        context.start();
        System.in.read();
        context.stop();
    }

    private void addJmsComponent(CamelContext context) {
        ActiveMQConnectionFactory cf = new ActiveMQConnectionFactory("tcp://localhost:61616");
        JmsConfiguration jmsConfig = new JmsConfiguration(cf);
View Full Code Here

        context.addComponent("jms", new JmsComponent(jmsConfig ));
        context.setTracing(true);
        context.addRoutes(new Jms2RestRoute());
        context.start();
        System.in.read();
        context.stop();
    }
   
    public static void main(String[] args) throws Exception {
        Jms2RestStarter starter = new Jms2RestStarter();
        starter.run();
View Full Code Here

        twitterComponent.setAccessTokenSecret("");
        context.setTracing(true);
        context.addRoutes(new VotingRoutes());
        context.start();
        System.in.read();
        context.stop();
    }
   
    public static void main(String[] args) throws Exception {
        VotingStarter starter = new VotingStarter();
        starter.run();
View Full Code Here

        assertEquals(camel2.getName(), listener.names.get(1));
        assertEquals(camel3.getName(), listener.names.get(2));

        camel1.stop();
        camel2.stop();
        camel3.stop();

        assertEquals(0, listener.names.size());
    }
}
View Full Code Here

                template.sendBodyAndHeaders("direct:in", payload, headers);
            }
            assertMockEndpointsSatisfied();
            return mock.getReceivedExchanges().get(0);
        } finally {
            context.stop();
        }
    }

    @Before
    public void setUp() throws Exception {
View Full Code Here

        Thread.sleep(100);
        camel.suspend();
        Thread.sleep(100);
        camel.resume();
        Thread.sleep(100);
        camel.stop();
        Thread.sleep(100);
        camel.start();
        Thread.sleep(100);
        camel.stop();
    }
View Full Code Here

        Thread.sleep(100);
        camel.stop();
        Thread.sleep(100);
        camel.start();
        Thread.sleep(100);
        camel.stop();
    }


    /**
     * Confirm the quartz trigger is removed on route stop.
View Full Code Here

                template.sendBodyAndHeaders("direct:in", payload, headers);
            }
            assertMockEndpointsSatisfied();
            return mock.getReceivedExchanges().get(0);
        } finally {
            context.stop();
        }
    }

    @Before
    public void setUp() throws Exception {
View Full Code Here

                template.sendBodyAndHeaders("direct:in", payload, headers);
            }
            assertMockEndpointsSatisfied();
            return mock.getReceivedExchanges().get(0);
        } finally {
            context.stop();
        }
    }

    @Before
    public void setUp() throws Exception {
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.