Search in sources :

Example 66 with JndiRegistry

use of org.apache.camel.impl.JndiRegistry in project camel by apache.

the class Http4UrlRewriteLoadBalanceFailoverTest method createRegistry.

@Override
protected JndiRegistry createRegistry() throws Exception {
    JndiRegistry jndi = super.createRegistry();
    HttpUrlRewrite myRewrite = new HttpUrlRewrite();
    myRewrite.setConfigFile("example/urlrewrite2.xml");
    jndi.bind("myRewrite", myRewrite);
    return jndi;
}
Also used : JndiRegistry(org.apache.camel.impl.JndiRegistry) HttpUrlRewrite(org.apache.camel.component.urlrewrite.HttpUrlRewrite)

Example 67 with JndiRegistry

use of org.apache.camel.impl.JndiRegistry in project camel by apache.

the class Http4UrlRewriteLoadBalanceRoundRobinTest method createRegistry.

@Override
protected JndiRegistry createRegistry() throws Exception {
    JndiRegistry jndi = super.createRegistry();
    HttpUrlRewrite myRewrite = new HttpUrlRewrite();
    myRewrite.setConfigFile("example/urlrewrite2.xml");
    jndi.bind("myRewrite", myRewrite);
    return jndi;
}
Also used : JndiRegistry(org.apache.camel.impl.JndiRegistry) HttpUrlRewrite(org.apache.camel.component.urlrewrite.HttpUrlRewrite)

Example 68 with JndiRegistry

use of org.apache.camel.impl.JndiRegistry in project camel by apache.

the class XAdESSignaturePropertiesTest method createRegistry.

@Override
protected JndiRegistry createRegistry() throws Exception {
    JndiRegistry registry = super.createRegistry();
    registry.bind("keyAccessorDefault", TestKeystore.getKeyAccessor("bob"));
    registry.bind("xmlSignatureProperties", getXmlSignatureProperties("bob"));
    Map<String, String> namespaceMap = Collections.singletonMap("ns", "http://test");
    List<XPathFilterParameterSpec> xpaths = Collections.singletonList(XmlSignatureHelper.getXpathFilter("/ns:root/a/@ID", namespaceMap));
    registry.bind("xpathsToIdAttributes", xpaths);
    return registry;
}
Also used : JndiRegistry(org.apache.camel.impl.JndiRegistry) XPathFilterParameterSpec(javax.xml.crypto.dsig.spec.XPathFilterParameterSpec)

Example 69 with JndiRegistry

use of org.apache.camel.impl.JndiRegistry in project camel by apache.

the class SqlTransactedRouteTest method createRegistry.

@Override
protected JndiRegistry createRegistry() throws Exception {
    JndiRegistry reg = super.createRegistry();
    db = new EmbeddedDatabaseBuilder().setType(EmbeddedDatabaseType.DERBY).build();
    reg.bind("testdb", db);
    DataSourceTransactionManager txMgr = new DataSourceTransactionManager();
    txMgr.setDataSource(db);
    reg.bind("txManager", txMgr);
    SpringTransactionPolicy txPolicy = new SpringTransactionPolicy();
    txPolicy.setTransactionManager(txMgr);
    txPolicy.setPropagationBehaviorName("PROPAGATION_REQUIRED");
    reg.bind("required", txPolicy);
    return reg;
}
Also used : JndiRegistry(org.apache.camel.impl.JndiRegistry) SpringTransactionPolicy(org.apache.camel.spring.spi.SpringTransactionPolicy) EmbeddedDatabaseBuilder(org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder) DataSourceTransactionManager(org.springframework.jdbc.datasource.DataSourceTransactionManager)

Example 70 with JndiRegistry

use of org.apache.camel.impl.JndiRegistry in project camel by apache.

the class SqlProducerAlwaysPopulateStatementFalseTest method createRegistry.

@Override
protected JndiRegistry createRegistry() throws Exception {
    JndiRegistry jndi = super.createRegistry();
    jndi.bind("myStrategy", strategy);
    return jndi;
}
Also used : JndiRegistry(org.apache.camel.impl.JndiRegistry)

Aggregations

JndiRegistry (org.apache.camel.impl.JndiRegistry)608 SSLContextParameters (org.apache.camel.util.jsse.SSLContextParameters)19 HttpUrlRewrite (org.apache.camel.component.urlrewrite.HttpUrlRewrite)18 KeyStoreParameters (org.apache.camel.util.jsse.KeyStoreParameters)17 DeadLetterChannelBuilder (org.apache.camel.builder.DeadLetterChannelBuilder)16 Properties (java.util.Properties)15 Test (org.junit.Test)14 TrustManagersParameters (org.apache.camel.util.jsse.TrustManagersParameters)13 ArrayList (java.util.ArrayList)11 KeyManagersParameters (org.apache.camel.util.jsse.KeyManagersParameters)11 EmbeddedDatabaseBuilder (org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder)11 File (java.io.File)10 RouteBuilder (org.apache.camel.builder.RouteBuilder)8 ExchangeCookieHandler (org.apache.camel.http.common.cookie.ExchangeCookieHandler)8 InstanceCookieHandler (org.apache.camel.http.common.cookie.InstanceCookieHandler)8 CamelContext (org.apache.camel.CamelContext)6 MockEndpoint (org.apache.camel.component.mock.MockEndpoint)6 BookCatalog (org.apache.camel.component.routebox.demo.BookCatalog)5 SimpleRouteBuilder (org.apache.camel.component.routebox.demo.SimpleRouteBuilder)5 DefaultCamelContext (org.apache.camel.impl.DefaultCamelContext)5