You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by ak...@apache.org on 2007/10/08 00:01:55 UTC
svn commit: r582688 - in /directory:
apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/
apacheds/branches/bigbang/server-xml/src/main/resources/
apacheds/branches/bigbang/server-xml/src/test/java/org/apache/directory/server/...
Author: akarasulu
Date: Sun Oct 7 15:01:54 2007
New Revision: 582688
URL: http://svn.apache.org/viewvc?rev=582688&view=rev
Log:
got latest changes incorporated into the server.xml
Modified:
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml
directory/apacheds/branches/bigbang/server-xml/src/test/java/org/apache/directory/server/SpringServerTest.java
directory/installers/branches/bigbang/apacheds-noarch/src/main/java/org/apache/directory/server/Service.java
directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/Entry.java
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?rev=582688&r1=582687&r2=582688&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java Sun Oct 7 15:01:54 2007
@@ -168,6 +168,7 @@
/**
* Gets the {@link Partition}s used by this DirectoryService.
*
+ * @org.apache.xbean.Property nestedType="org.apache.directory.server.core.partition.Partition"
* @return the set of partitions used
*/
public Set<? extends Partition> getPartitions()
@@ -181,6 +182,7 @@
/**
* Sets {@link Partition}s used by this DirectoryService.
*
+ * @org.apache.xbean.Property nestedType="org.apache.directory.server.core.partition.Partition"
* @param partitions the partitions to used
*/
public void setPartitions( Set<? extends Partition> partitions )
@@ -267,6 +269,7 @@
/**
* Sets the interceptors in the server.
*
+ * @org.apache.xbean.Property nestedType="org.apache.directory.server.core.interceptor.Interceptor"
* @param interceptors the interceptors to be used in the server.
*/
public void setInterceptors( List<Interceptor> interceptors )
@@ -290,6 +293,7 @@
* Returns test directory entries({@link Entry}) to be loaded while
* bootstrapping.
*
+ * @org.apache.xbean.Property nestedType="org.apache.directory.shared.ldap.ldif.Entry"
* @return test entries to load during bootstrapping
*/
public List<Entry> getTestEntries()
@@ -304,6 +308,7 @@
* Sets test directory entries({@link Attributes}) to be loaded while
* bootstrapping.
*
+ * @org.apache.xbean.Property nestedType="org.apache.directory.shared.ldap.ldif.Entry"
* @param testEntries the test entries to load while bootstrapping
*/
public void setTestEntries( List<? extends Entry> testEntries )
Modified: directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml?rev=582688&r1=582687&r2=582688&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml (original)
+++ directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml Sun Oct 7 15:01:54 2007
@@ -4,127 +4,63 @@
"http://www.springframework.org/dtd/spring-beans.dtd">
<beans>
-<!-- bean I didn't convert -->
- <bean id="environment" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
- <property name="properties">
- <props>
- <!-- JNDI security properties used to get initial contexts. -->
- <prop key="java.naming.security.authentication">simple</prop>
- <prop key="java.naming.security.principal">uid=admin,ou=system</prop>
- <prop key="java.naming.security.credentials">secret</prop>
- </props>
- </property>
- </bean>
-
- <apacheDS id="defaultApacheDS" xmlns="http://apacheds.org/config/1.0"
- synchPeriodMillis="15000"
- maxThreads="8"
- allowAnonymousAccess="false">
-
- <defaultDirectoryService id="defaultDirectoryService"
- instanceId="default"
- workingDirectory="example.com"
- allowAnonymousAccess="false"
- accessControlEnabled="false"
- denormalizeOpAttrsEnabled="false"
- >
+ <apacheDS id="apacheDS" xmlns="http://apacheds.org/config/1.0"
+ synchPeriodMillis="15000"
+ maxThreads="8"
+ allowAnonymousAccess="false">
+
+ <directoryService>
+ <defaultDirectoryService id="directoryService" instanceId="default"
+ workingDirectory="example.com"
+ allowAnonymousAccess="false"
+ accessControlEnabled="false"
+ denormalizeOpAttrsEnabled="false">
<systemPartition>
<!-- use the following partitionConfiguration to override defaults for -->
<!-- the system partition -->
-
- <jdbmPartition
- id="system"
- cacheSize="100"
- suffix="ou=system"
- optimizerEnabled="true"
- syncOnWrite="true">
+ <jdbmPartition id="system" cacheSize="100" suffix="ou=system" optimizerEnabled="true" syncOnWrite="true">
<indexedAttributes>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.1"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.2"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.3"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.4"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.5"
- cacheSize="10"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.6"
- cacheSize="10"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.7"
- cacheSize="10"/>
- <jdbmIndex
- attributeId="ou"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="uid"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="objectClass"
- cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.1" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.2" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.3" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.4" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.5" cacheSize="10"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.6" cacheSize="10"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.7" cacheSize="10"/>
+ <jdbmIndex attributeId="ou" cacheSize="100"/>
+ <jdbmIndex attributeId="uid" cacheSize="100"/>
+ <jdbmIndex attributeId="objectClass" cacheSize="100"/>
</indexedAttributes>
<contextEntry>
<value xmlns="http://www.springframework.org/schema/beans">
- objectClass: top
- objectClass: organizationalUnit
- objectClass: extensibleObject
- ou: system
+ objectClass: top
+ objectClass: organizationalUnit
+ objectClass: extensibleObject
+ ou: system
</value>
</contextEntry>
</jdbmPartition>
</systemPartition>
<partitions>
- <jdbmPartition
- id="example"
- cacheSize="100"
- suffix="dc=example,dc=com"
- optimizerEnabled="true"
- syncOnWrite="true">
+ <!-- NOTE: when specifying new partitions you need not include those -->
+ <!-- attributes below with OID's which are the system indices, if left -->
+ <!-- out they will be automatically configured for you with defaults. -->
+ <jdbmPartition id="example" cacheSize="100" suffix="dc=example,dc=com" optimizerEnabled="true"
+ syncOnWrite="true">
<indexedAttributes>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.1"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.2"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.3"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.4"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.5"
- cacheSize="10"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.6"
- cacheSize="10"/>
- <jdbmIndex
- attributeId="1.3.6.1.4.1.18060.0.4.1.2.7"
- cacheSize="10"/>
- <jdbmIndex
- attributeId="dc"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="ou"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="krb5PrincipalName"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="uid"
- cacheSize="100"/>
- <jdbmIndex
- attributeId="objectClass"
- cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.1" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.2" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.3" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.4" cacheSize="100"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.5" cacheSize="10"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.6" cacheSize="10"/>
+ <jdbmIndex attributeId="1.3.6.1.4.1.18060.0.4.1.2.7" cacheSize="10"/>
+ <jdbmIndex attributeId="dc" cacheSize="100"/>
+ <jdbmIndex attributeId="ou" cacheSize="100"/>
+ <jdbmIndex attributeId="krb5PrincipalName" cacheSize="100"/>
+ <jdbmIndex attributeId="uid" cacheSize="100"/>
+ <jdbmIndex attributeId="objectClass" cacheSize="100"/>
</indexedAttributes>
<contextEntry>
<value xmlns="http://www.springframework.org/schema/beans">
@@ -160,9 +96,7 @@
<!-- Uncomment to enable replication service
<replicationService >
<configuration>
- <replicationConfiguration
- serverPort="10390"
- peerReplicas="instance_b@localhost:10392">
+ <replicationConfiguration serverPort="10390" peerReplicas="instance_b@localhost:10392">
<replicaId>
<replicaId id="instance_a"/>
</replicaId>
@@ -170,91 +104,68 @@
</configuration>
</replicationService>
-->
-
</interceptors>
</defaultDirectoryService>
+ </directoryService>
-
- <changePasswordConfiguration>
- <changePasswordConfiguration
- enabled="false"
- ipPort="464">
- </changePasswordConfiguration>
- </changePasswordConfiguration>
-
- <ntpConfiguration>
- <ntpConfiguration
- enabled="false"
- ipPort="123">
- </ntpConfiguration>
- </ntpConfiguration>
-
- <dnsConfiguration>
- <dnsConfiguration
- enabled="false"
- ipPort="53">
- </dnsConfiguration>
- </dnsConfiguration>
-
- <kdcConfiguration>
- <kdcConfiguration
- enabled="false"
- ipPort="88">
- </kdcConfiguration>
- </kdcConfiguration>
-
- <ldapsConfiguration>
- <ldapConfiguration id="ldapsConfiguration"
- enabled="false"
- ipPort="636"
- enableLdaps="true">
- </ldapConfiguration>
- </ldapsConfiguration>
-
- <ldapConfiguration>
- <ldapConfiguration id="ldapConfiguration"
- ipPort="10389"
- allowAnonymousAccess="false"
- saslHost="ldap.example.com"
- saslPrincipal="ldap/ldap.example.com@EXAMPLE.COM"
- searchBaseDn="ou=users,ou=system"
- maxTimeLimit="15000"
- maxSizeLimit="1000">
-
- <!-- The list of supported authentication mechanisms. -->
- <supportedMechanisms>
- <value xmlns="http://www.springframework.org/schema/beans">SIMPLE</value>
- <value xmlns="http://www.springframework.org/schema/beans">CRAM-MD5</value>
- <value xmlns="http://www.springframework.org/schema/beans">DIGEST-MD5</value>
- <!--<value xmlns="http://www.springframework.org/schema/beans">GSSAPI</value>-->
- </supportedMechanisms>
-
- <!-- The desired quality-of-protection, used by DIGEST-MD5 and GSSAPI. -->
- <saslQop>
- <value xmlns="http://www.springframework.org/schema/beans">auth</value>
- <value xmlns="http://www.springframework.org/schema/beans">auth-int</value>
- <value xmlns="http://www.springframework.org/schema/beans">auth-conf</value>
- </saslQop>
-
- <!-- The realms serviced by this SASL host, used by DIGEST-MD5 and GSSAPI. -->
- <saslRealms>
- <value xmlns="http://www.springframework.org/schema/beans">example.com</value>
- <value xmlns="http://www.springframework.org/schema/beans">apache.org</value>
- </saslRealms>
-
- <!-- the collection of extended operation handlers to install -->
- <extendedOperationHandlers>
- <!--startTlsHandler/-->
- <gracefulShutdownHandler/>
- <launchDiagnosticUiHandler/>
- <!-- The Stored Procedure Extended Operation is not stable yet and it may cause security risks.-->
- <!--storedProcedureExtendedOperationHandler/-->
- </extendedOperationHandlers>
- </ldapConfiguration>
+ <changePasswordConfiguration>
+ <changePasswordConfiguration enabled="false" ipPort="464"/>
+ </changePasswordConfiguration>
+
+ <ntpConfiguration>
+ <ntpConfiguration enabled="false" ipPort="123"/>
+ </ntpConfiguration>
+
+ <dnsConfiguration>
+ <dnsConfiguration enabled="false" ipPort="53"/>
+ </dnsConfiguration>
+
+ <kdcConfiguration>
+ <kdcConfiguration enabled="false" ipPort="88"/>
+ </kdcConfiguration>
+
+ <ldapsConfiguration>
+ <ldapConfiguration enabled="false" ipPort="636" enableLdaps="true"/>
+ </ldapsConfiguration>
+
+ <ldapConfiguration>
+ <ldapConfiguration ipPort="10389" allowAnonymousAccess="false" saslHost="ldap.example.com"
+ saslPrincipal="ldap/ldap.example.com@EXAMPLE.COM" searchBaseDn="ou=users,ou=system"
+ maxTimeLimit="15000" maxSizeLimit="1000">
+ <!-- The list of supported authentication mechanisms. -->
+ <supportedMechanisms>
+ <value xmlns="http://www.springframework.org/schema/beans">SIMPLE</value>
+ <value xmlns="http://www.springframework.org/schema/beans">CRAM-MD5</value>
+ <value xmlns="http://www.springframework.org/schema/beans">DIGEST-MD5</value>
+ <!--<value xmlns="http://www.springframework.org/schema/beans">GSSAPI</value>-->
+ </supportedMechanisms>
+
+ <!-- The desired quality-of-protection, used by DIGEST-MD5 and GSSAPI. -->
+ <saslQop>
+ <value xmlns="http://www.springframework.org/schema/beans">auth</value>
+ <value xmlns="http://www.springframework.org/schema/beans">auth-int</value>
+ <value xmlns="http://www.springframework.org/schema/beans">auth-conf</value>
+ </saslQop>
+
+ <!-- The realms serviced by this SASL host, used by DIGEST-MD5 and GSSAPI. -->
+ <saslRealms>
+ <value xmlns="http://www.springframework.org/schema/beans">example.com</value>
+ <value xmlns="http://www.springframework.org/schema/beans">apache.org</value>
+ </saslRealms>
+
+ <!-- the collection of extended operation handlers to install -->
+ <extendedOperationHandlers>
+ <!--startTlsHandler/-->
+ <gracefulShutdownHandler/>
+ <launchDiagnosticUiHandler/>
+ <!-- The Stored Procedure Extended Operation is not stable yet and it may cause security risks.-->
+ <!--storedProcedureExtendedOperationHandler/-->
+ </extendedOperationHandlers>
</ldapConfiguration>
+ </ldapConfiguration>
</apacheDS>
-<!-- another bean I didn't convert -->
+ <!-- another bean I didn't convert -->
<bean class="org.springframework.beans.factory.config.CustomEditorConfigurer">
<property name="customEditors">
<map>
Modified: directory/apacheds/branches/bigbang/server-xml/src/test/java/org/apache/directory/server/SpringServerTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/server-xml/src/test/java/org/apache/directory/server/SpringServerTest.java?rev=582688&r1=582687&r2=582688&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/server-xml/src/test/java/org/apache/directory/server/SpringServerTest.java (original)
+++ directory/apacheds/branches/bigbang/server-xml/src/test/java/org/apache/directory/server/SpringServerTest.java Sun Oct 7 15:01:54 2007
@@ -46,14 +46,7 @@
File configF = new File( configURL.toURI() );
ApplicationContext factory = new FileSystemXmlApplicationContext( configF.toURL().toString() );
ApacheDS apacheDS = ( ApacheDS ) factory.getBean( "apacheDS" );
- //noinspection unchecked
- Hashtable<String,Object> env = ( Hashtable ) factory.getBean( "environment" );
- env.put( ApacheDS.JNDI_KEY, apacheDS );
- env.put( Context.PROVIDER_URL, providerURL );
- env.put( Context.INITIAL_CONTEXT_FACTORY, ServerContextFactory.class.getName() );
-
File workingDirFile = new File( configF.getParentFile(), "work" );
apacheDS.getDirectoryService().setWorkingDirectory( workingDirFile );
- new InitialDirContext( env );
}
}
Modified: directory/installers/branches/bigbang/apacheds-noarch/src/main/java/org/apache/directory/server/Service.java
URL: http://svn.apache.org/viewvc/directory/installers/branches/bigbang/apacheds-noarch/src/main/java/org/apache/directory/server/Service.java?rev=582688&r1=582687&r2=582688&view=diff
==============================================================================
--- directory/installers/branches/bigbang/apacheds-noarch/src/main/java/org/apache/directory/server/Service.java (original)
+++ directory/installers/branches/bigbang/apacheds-noarch/src/main/java/org/apache/directory/server/Service.java Sun Oct 7 15:01:54 2007
@@ -54,32 +54,24 @@
printBanner();
long startTime = System.currentTimeMillis();
- Hashtable<String, Object> env;
if ( args.length > 0 && new File( args[0] ).exists() ) // hack that takes server.xml file argument
{
LOG.info( "server: loading settings from ", args[0] );
ApplicationContext factory = new ClassPathXmlApplicationContext( new File( args[0] ).toURI().toURL().toString() );
apacheDS = ( ApacheDS ) factory.getBean( "apacheDS" );
- //noinspection unchecked
- env = ( Hashtable ) factory.getBean( "environment" );
}
else
{
LOG.info( "server: using default settings ..." );
- env = new Hashtable<String,Object>();
apacheDS = new ApacheDS();
}
- env.put( ApacheDS.JNDI_KEY, apacheDS );
- env.put( Context.PROVIDER_URL, "ou=system" );
- env.put( Context.INITIAL_CONTEXT_FACTORY, ServerContextFactory.class.getName() );
-
if ( install != null )
{
apacheDS.getDirectoryService().setWorkingDirectory( install.getPartitionsDirectory() );
}
- new InitialDirContext( env );
+ apacheDS.startup();
if ( apacheDS.getSynchPeriodMillis() > 0 )
{
Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/Entry.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/Entry.java?rev=582688&r1=582687&r2=582688&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/Entry.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/Entry.java Sun Oct 7 15:01:54 2007
@@ -38,6 +38,7 @@
import org.apache.directory.shared.ldap.message.ModificationItemImpl;
import org.apache.directory.shared.ldap.util.StringTools;
+
/**
* A entry to be populated by an ldif parser.
*