DATALDAP-1 - Create namespace handler and XML schema.
Spring Data LDAP now uses its own Namespace: http://www.springframework.org/schema/data/ldap. Using XML configuration for Spring LDAP and Spring Data LDAP requires both namespaces to be declared. <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ldap="http://www.springframework.org/schema/ldap" xmlns:data-ldap="http://www.springframework.org/schema/data/ldap" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/ldap http://www.springframework.org/schema/ldap/spring-ldap.xsd http://www.springframework.org/schema/data/ldap http://www.springframework.org/schema/data/ldap/spring-ldap.xsd"> <ldap:context-source password="apassword" url="ldap://localhost:389" username="uid=admin"/> <ldap:ldap-template/> <data-ldap:repositories base-package="org.springframework.data.ldap.config"/> </beans>
This commit is contained in:
11
src/test/resources/infrastructure.xml
Normal file
11
src/test/resources/infrastructure.xml
Normal file
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:ldap="http://www.springframework.org/schema/ldap"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/ldap http://www.springframework.org/schema/ldap/spring-ldap.xsd">
|
||||
|
||||
<ldap:context-source password="apassword" url="ldap://localhost:389" username="uid=admin"/>
|
||||
|
||||
<ldap:ldap-template/>
|
||||
</beans>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:data-ldap="http://www.springframework.org/schema/data/ldap"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/data/ldap http://www.springframework.org/schema/data/ldap/spring-ldap.xsd">
|
||||
|
||||
<import resource="classpath:infrastructure.xml" />
|
||||
|
||||
<data-ldap:repositories base-package="org.springframework.data.ldap.config"/>
|
||||
|
||||
</beans>
|
||||
Reference in New Issue
Block a user