Hi everyone,
I would like to get a simple LDAP-example (basically an xmlified variant from
the ldap-component-page) running. However, my blueprint.xml is invalid with
regard to the schemas because of the "constructor-arg" element.
E [Xerces] cvc-complex-type.2.4.a: Invalid content was found starting with
element 'constructor-arg'. One of
'{"http://www.osgi.org/xmlns/blueprint/v1.0.0":description,
"http://www.osgi.org/xmlns/blueprint/v1.0.0":argument,
"http://www.osgi.org/xmlns/blueprint/v1.0.0":property,
WC[##other:"http://www.osgi.org/xmlns/blueprint/v1.0.0"]}' is expected.
Is there another way to get these properties set?
I am a bit of a camel-noob, so any hint what I am missing is really appreciated.
Regards, Thomas.
----
<?xml version="1.0" encoding="UTF-8"?>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:camel="http://camel.apache.org/schema/blueprint"
xsi:schemaLocation="
http://www.osgi.org/xmlns/blueprint/v1.0.0
http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://camel.apache.org/schema/blueprint
http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
<bean id="shutdown" class="org.apache.camel.impl.DefaultShutdownStrategy">
<property name="timeout" value="10"/>
</bean>
<bean id="ldapserver" class="javax.naming.directory.InitialDirContext"
scope="prototype">
<constructor-arg>
<props>
<prop
key="javax.naming.factory.initial">com.sun.jndi.ldap.LdapCtxFactory</prop>
<prop
key="javax.naming.provider.url">ldap://myldap.mydomain.com</prop>
<prop
key="javax.naming.security.authentication">none</prop>
</props>
</constructor-arg>
</bean>
<camelContext trace="false" id="ctxLDAP"
xmlns="http://camel.apache.org/schema/blueprint">
<route id="rtLDAP" autoStartup="true">
<from uri="timer://foo?period=60000"/>
<setBody>
<constant>(sn=*)</constant>
</setBody>
<to uri="ldap:ldapserver"/>
<log message="=== ${body}"/>
</route>
</camelContext>
</blueprint>
-----
My environment:
camel-2.8.0.fuse-06-11
java 1.6.0_27
karaf 2.2.2-fuse-07-11
Windows 2003 R2