Examples of JpaComponent


Examples of org.apache.camel.component.jpa.JpaComponent

    protected JpaTemplate jpaTemplate;

    @Test
    public void testRouteJpa() throws Exception {
        // should auto setup transaction manager and entity factory
        JpaComponent jpa = context.getComponent("jpa", JpaComponent.class);
        assertNotNull("Should have been auto assigned", jpa.getEntityManagerFactory());
        assertNotNull("Should have been auto assigned", jpa.getTransactionManager());

        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedMessageCount(1);

        template.sendBody("direct:start", new SendEmail("someone@somewhere.org"));
View Full Code Here

Examples of org.apache.camel.component.jpa.JpaComponent

    protected JpaTemplate jpaTemplate;

    @Test
    public void testRouteJpa() throws Exception {
        // should auto setup transaction manager and entity factory
        JpaComponent jpa = context.getComponent("jpa", JpaComponent.class);
        assertNotNull("Should have been auto assigned", jpa.getEntityManagerFactory());
        assertNotNull("Should have been auto assigned", jpa.getTransactionManager());

        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedMessageCount(1);

        template.sendBody("direct:start", new SendEmail("someone@somewhere.org"));
View Full Code Here

Examples of org.apache.camel.component.jpa.JpaComponent

    protected JpaTemplate jpaTemplate;

    @Test
    public void testRouteJpa() throws Exception {
        // should auto setup transaction manager and entity factory
        JpaComponent jpa = context.getComponent("jpa", JpaComponent.class);
        assertNotNull("Should have been auto assigned", jpa.getEntityManagerFactory());
        assertNotNull("Should have been auto assigned", jpa.getTransactionManager());

        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedMessageCount(1);

        template.sendBody("direct:start", new SendEmail("someone@somewhere.org"));
View Full Code Here

Examples of org.apache.camel.component.jpa.JpaComponent

    protected static final String SELECT_ALL_STRING = "select x from " + SendEmail.class.getName() + " x";

    @Test
    public void testRouteJpa() throws Exception {
        // should auto setup transaction manager and entity factory
        JpaComponent jpa = context.getComponent("jpa", JpaComponent.class);
        assertNotNull("Should have been auto assigned", jpa.getEntityManagerFactory());
        assertNotNull("Should have been auto assigned", jpa.getTransactionManager());

        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedMessageCount(1);
        ValueBuilder header = mock.message(0).header(JpaConstants.ENTITYMANAGER);
        header.isNotNull();
View Full Code Here

Examples of org.apache.camel.component.jpa.JpaComponent

    protected static final String SELECT_ALL_STRING = "select x from " + SendEmail.class.getName() + " x";

    @Test
    public void testRouteJpa() throws Exception {
        // should auto setup transaction manager and entity factory
        JpaComponent jpa = context.getComponent("jpa", JpaComponent.class);
        assertNotNull("Should have been auto assigned", jpa.getEntityManagerFactory());
        assertNotNull("Should have been auto assigned", jpa.getTransactionManager());

        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedMessageCount(1);

        template.sendBody("direct:start", new SendEmail("someone@somewhere.org"));
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.