Examples of EndpointConfiguration


Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        ServletComponent comp = context.getComponent("servlet", ServletComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("servlet://foo?servletName=MyServlet&proxyHost=myotherproxy&proxyPort=2345");

        assertEquals("myotherproxy", conf.getParameter("proxyHost"));
        assertEquals("2345", conf.getParameter("proxyPort"));
        assertEquals("MyServlet", conf.getParameter("servletName"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        NettyHttpComponent comp = context.getComponent("netty-http", NettyHttpComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("netty-http:tcp://localhost:5150?sync=true"
                + "&httpMethodRestrict=POST&traceEnabled=true");

        assertEquals("true", conf.getParameter("traceEnabled"));
        assertEquals("POST", conf.getParameter("httpMethodRestrict"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        ElasticsearchComponent comp = context.getComponent("elasticsearch", ElasticsearchComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("elasticsearch://clustername?operation=INDEX&indexName=twitter&indexType=tweet&ip=127.0.0.1");

        assertEquals("INDEX", conf.getParameter("operation"));
        assertEquals("tweet", conf.getParameter("indexType"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        NettyComponent comp = context.getComponent("netty", NettyComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("netty:tcp://localhost:5150?sync=true"
                + "&maximumPoolSize=32&ssl=true&passphrase=#password");

        assertEquals("true", conf.getParameter("sync"));
        assertEquals("32", conf.getParameter("maximumPoolSize"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        HttpComponent comp = context.getComponent("http4", HttpComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("http4://www.google.com?proxyAuthHost=myproxy&"
                + "proxyAuthPort=1234&chunked=false");

        assertEquals("myproxy", conf.getParameter("proxyAuthHost"));
        assertEquals("false", conf.getParameter("chunked"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        JettyHttpComponent comp = context.getComponent("jetty", JettyHttpComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("jetty://http://localhost:8080/myapp?"
                + "httpClientMinThreads=4&httpClientMaxThreads=8");

        assertEquals("4", conf.getParameter("httpClientMinThreads"));
        assertEquals("8", conf.getParameter("httpClientMaxThreads"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        GLoginComponent comp = context.getComponent("glogin", GLoginComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("glogin:localhost?devMode=true&devAdmin=true");

        assertEquals("true", conf.getParameter("devMode"));
        assertEquals("true", conf.getParameter("devAdmin"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    @Test
    public void testComponentConfiguration() throws Exception {
        CamelContext context = new DefaultCamelContext();

        BeanstalkComponent comp = context.getComponent("beanstalk", BeanstalkComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("beanstalk:tube?command=put");

        assertEquals("put", conf.getParameter("command"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    }

    @Test
    public void testComponentConfiguration() throws Exception {
        OpenShiftComponent comp = context.getComponent("openshift", OpenShiftComponent.class);
        EndpointConfiguration conf = comp.createConfiguration("openshift:myApp?username=foo&password=secret&operation=list");

        assertEquals("foo", conf.getParameter("username"));
        assertEquals("secret", conf.getParameter("password"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
View Full Code Here

Examples of org.apache.camel.EndpointConfiguration

    @Test
    public void testComponentConfiguration() throws Exception {
        InfinispanComponent comp = context.getComponent("infinispan", InfinispanComponent.class);
        String configUri = "infinispan://localhost?cacheContainer=#cacheContainer&sync=false&eventTypes=CACHE_ENTRY_CREATED";
        EndpointConfiguration conf = comp.createConfiguration(configUri);

        assertEquals("localhost", conf.getParameter("host"));
        assertEquals("cacheContainer=", conf.getParameter("query"));

        ComponentConfiguration compConf = comp.createComponentConfiguration();
        String json = compConf.createParameterJsonSchema();
        assertNotNull(json);
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.