The below mentioned code snippet works as you expected.

CamelContext context = new DefaultCamelContext();
        context.addRoutes(new RouteBuilder()
        {
            @Override
            public void configure() throws Exception
            {
                from("direct:start").process(new Processor()
                {
                    @Override
                    public void process(Exchange exchange) throws Exception
                    {
                        System.out.println("control in
processor!!!!!!!!!!!!!!!");
                    }
                });
            }
        });
        context.start();
        Thread.sleep(1000);
        ProducerTemplate template = context.createProducerTemplate();
        template.sendBody("direct:start", "Test Message"); 
        context.stop();



--
View this message in context: 
http://camel.465427.n5.nabble.com/How-to-called-the-processor-tp5737769p5737941.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to