Package org.springframework.context.support

Examples of org.springframework.context.support.ClassPathXmlApplicationContext.stop()


        MockEndpoint mock2 = camel2.getEndpoint("mock:result", MockEndpoint.class);
        mock2.expectedMinimumMessageCount(3);

        mock2.assertIsSatisfied();

        app2.stop();
    }

}
View Full Code Here


        // as opposed to the CamelClientRemoting example we need to define the service URI in this java code
        int response = (Integer)camelTemplate.sendBody("jms:queue:numbers", ExchangePattern.InOut, 22);
       
        assertEquals("Get a wrong response", 66, response);
       
        context.stop();
       
    }
   
    protected void camelEndpointInvocation() throws Exception {
       
View Full Code Here

       
        assertEquals("Get a wrong response.", 33, response);

        // stop and exit the client
        producer.stop();
        context.stop();
       
    }
   
    protected void camelRemotingInvocation() {
View Full Code Here

      
        int response = multiplier.multiply(33);
       
        assertEquals("Get a wrong response", 99, response);
       
        context.stop();
       
    }

}
View Full Code Here

        // as opposed to the CamelClientRemoting example we need to define the service URI in this java code
        int response = (Integer)camelTemplate.sendBody("jms:queue:numbers", ExchangePattern.InOut, 22);
       
        assertEquals("Get a wrong response", 66, response);
       
        context.stop();
    }
   
    @Test
    public void testCamelEndpointInvocation() throws Exception {
        ConfigurableApplicationContext context = new ClassPathXmlApplicationContext("camel-client.xml");
View Full Code Here

       
        assertEquals("Get a wrong response.", 33, response);

        // stop and exit the client
        producer.stop();
        context.stop();
    }
   
    @Test
    public void testCamelRemotingInvocation() {
        ConfigurableApplicationContext context = new ClassPathXmlApplicationContext("camel-client-remoting.xml");
View Full Code Here

      
        int response = multiplier.multiply(33);
       
        assertEquals("Get a wrong response", 99, response);
       
        context.stop();
    }

}
View Full Code Here

        CamelContext camelContext = (CamelContext)applicationContext.getBean("myCamel");
        assertNotNull("The camel context should not be null", camelContext);

        Thread.sleep(2000);
        camelContext.stop();
        applicationContext.stop();       
    }

}
View Full Code Here

            CamelContext camelContext = (CamelContext)applicationContext.getBean("queue");
            assertNotNull("The camel context should not be null", camelContext);
   
            Thread.sleep(2000);
            camelContext.stop();
            applicationContext.stop();
        } finally {
            broker.stop();
        }
    }
View Full Code Here

                applicationContext.start();

            }

            public void stop() throws Exception {
                applicationContext.stop();
            }
        });

        return SpringCamelContext.springCamelContext(applicationContext);      
    }
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.