You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2012/01/24 17:27:22 UTC

svn commit: r1235334 [2/6] - in /directory/apacheds/trunk: ldap-client-test/src/test/java/org/apache/directory/shared/client/api/ ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/ ldap-client-test/src/test/java/org/apach...

Modified: directory/apacheds/trunk/service-builder/src/main/java/org/apache/directory/server/config/builder/ServiceBuilder.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/service-builder/src/main/java/org/apache/directory/server/config/builder/ServiceBuilder.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/service-builder/src/main/java/org/apache/directory/server/config/builder/ServiceBuilder.java (original)
+++ directory/apacheds/trunk/service-builder/src/main/java/org/apache/directory/server/config/builder/ServiceBuilder.java Tue Jan 24 16:27:18 2012
@@ -133,7 +133,7 @@ public class ServiceBuilder
             return Strings.toLowerCase( file.getName() ).endsWith( ".ldif" );
         }
     };
-    
+
 
     /**
      * Creates the Interceptor instances from the configuration
@@ -145,7 +145,7 @@ public class ServiceBuilder
     public static List<Interceptor> createInterceptors( List<InterceptorBean> interceptorBeans ) throws LdapException
     {
         List<Interceptor> interceptors = new ArrayList<Interceptor>( interceptorBeans.size() );
-        
+
         // First order the interceptorBeans
         Set<InterceptorBean> orderedInterceptorBeans = new TreeSet<InterceptorBean>();
 
@@ -162,22 +162,27 @@ public class ServiceBuilder
         {
             try
             {
-                LOG.debug( "loading the interceptor class {} and instantiating", interceptorBean.getInterceptorClassName() );
-                Interceptor interceptor = ( Interceptor ) Class.forName( interceptorBean.getInterceptorClassName() ).newInstance();
-                
-                if (interceptorBean instanceof AuthenticationInterceptorBean) {
+                LOG.debug( "loading the interceptor class {} and instantiating",
+                    interceptorBean.getInterceptorClassName() );
+                Interceptor interceptor = ( Interceptor ) Class.forName( interceptorBean.getInterceptorClassName() )
+                    .newInstance();
+
+                if ( interceptorBean instanceof AuthenticationInterceptorBean )
+                {
                     // Transports
-                    Authenticator[] authenticators = createAuthenticators( ((AuthenticationInterceptorBean)interceptorBean).getAuthenticators() );
-                    ((AuthenticationInterceptor) interceptor).setAuthenticators( authenticators );
-                    
+                    Authenticator[] authenticators = createAuthenticators( ( ( AuthenticationInterceptorBean ) interceptorBean )
+                        .getAuthenticators() );
+                    ( ( AuthenticationInterceptor ) interceptor ).setAuthenticators( authenticators );
+
                     // password policies
-                    List<PasswordPolicyBean> ppolicyBeans = ((AuthenticationInterceptorBean)interceptorBean).getPasswordPolicies();
-                    PpolicyConfigContainer ppolicyContainer = new  PpolicyConfigContainer();
+                    List<PasswordPolicyBean> ppolicyBeans = ( ( AuthenticationInterceptorBean ) interceptorBean )
+                        .getPasswordPolicies();
+                    PpolicyConfigContainer ppolicyContainer = new PpolicyConfigContainer();
 
                     for ( PasswordPolicyBean ppolicyBean : ppolicyBeans )
                     {
                         PasswordPolicyConfiguration ppolicyConfig = createPwdPolicyConfig( ppolicyBean );
-                        
+
                         if ( ppolicyConfig != null )
                         {
                             // the name should be strictly 'default', the default policy can't be enforced by defining a new AT
@@ -191,25 +196,26 @@ public class ServiceBuilder
                             }
                         }
                     }
-                    
+
                     ( ( AuthenticationInterceptor ) interceptor ).setPwdPolicies( ppolicyContainer );
                 }
-                
+
                 interceptors.add( interceptor );
             }
             catch ( Exception e )
             {
                 e.printStackTrace();
-                String message = "Cannot initialize the " + interceptorBean.getInterceptorClassName() + ", error : " + e;
+                String message = "Cannot initialize the " + interceptorBean.getInterceptorClassName() + ", error : "
+                    + e;
                 LOG.error( message );
                 throw new ConfigurationException( message );
             }
         }
-        
+
         return interceptors;
     }
-    
-    
+
+
     /**
      * creates the PassworddPolicyConfiguration object after reading the config entry containing pwdpolicy OC
      *
@@ -222,9 +228,9 @@ public class ServiceBuilder
         {
             return null;
         }
-        
+
         PasswordPolicyConfiguration passwordPolicy = new PasswordPolicyConfiguration();
-        
+
         passwordPolicy.setPwdAllowUserChange( passwordPolicyBean.isPwdAllowUserChange() );
         passwordPolicy.setPwdAttribute( passwordPolicyBean.getPwdAttribute() );
         passwordPolicy.setPwdCheckQuality( passwordPolicyBean.getPwdCheckQuality() );
@@ -245,11 +251,11 @@ public class ServiceBuilder
         passwordPolicy.setPwdMinLength( passwordPolicyBean.getPwdMinLength() );
         passwordPolicy.setPwdMustChange( passwordPolicyBean.isPwdMustChange() );
         passwordPolicy.setPwdSafeModify( passwordPolicyBean.isPwdSafeModify() );
-        
+
         return passwordPolicy;
     }
 
-    
+
     /**
      * Read the configuration for the ChangeLog system
      * 
@@ -262,16 +268,16 @@ public class ServiceBuilder
         {
             return null;
         }
-        
+
         ChangeLog changeLog = new DefaultChangeLog();
-        
+
         changeLog.setEnabled( changeLogBean.isEnabled() );
         changeLog.setExposed( changeLogBean.isChangeLogExposed() );
 
         return changeLog;
     }
-    
-    
+
+
     /**
      * Instantiate the Journal object from the stored configuration
      * 
@@ -284,7 +290,7 @@ public class ServiceBuilder
         {
             return null;
         }
-        
+
         Journal journal = new DefaultJournal();
 
         journal.setRotation( journalBean.getJournalRotation() );
@@ -296,7 +302,7 @@ public class ServiceBuilder
         store.setWorkingDirectory( journalBean.getJournalWorkingDir() );
 
         journal.setJournalStore( store );
-        
+
         return journal;
     }
 
@@ -321,7 +327,7 @@ public class ServiceBuilder
         else
         {
             LOG.debug( "parsing the LDIF file(s) present at the path {}", entryFilePath );
-            
+
             try
             {
                 loadEntries( file, entries );
@@ -342,7 +348,7 @@ public class ServiceBuilder
 
         return entries;
     }
-    
+
 
     /**
      * Load the entries from a Ldif file recursively
@@ -363,7 +369,7 @@ public class ServiceBuilder
         else
         {
             LdifReader reader = new LdifReader();
-            
+
             try
             {
                 entries.addAll( reader.parseLdifFile( ldifFile.getAbsolutePath() ) );
@@ -383,17 +389,18 @@ public class ServiceBuilder
      * @return an instance of the MechanismHandler type
      * @throws ConfigurationException if the SASL mechanism handler cannot be created
      */
-    public static MechanismHandler createSaslMechHandler( SaslMechHandlerBean saslMechHandlerBean ) throws ConfigurationException
+    public static MechanismHandler createSaslMechHandler( SaslMechHandlerBean saslMechHandlerBean )
+        throws ConfigurationException
     {
         if ( ( saslMechHandlerBean == null ) || saslMechHandlerBean.isDisabled() )
         {
             return null;
         }
-        
+
         String mechClassName = saslMechHandlerBean.getSaslMechClassName();
-        
+
         Class<?> mechClass = null;
-        
+
         try
         {
             mechClass = Class.forName( mechClassName );
@@ -404,9 +411,9 @@ public class ServiceBuilder
             LOG.error( message );
             throw new ConfigurationException( message );
         }
-        
+
         MechanismHandler handler = null;
-        
+
         try
         {
             handler = ( MechanismHandler ) mechClass.newInstance();
@@ -423,57 +430,63 @@ public class ServiceBuilder
             LOG.error( message );
             throw new ConfigurationException( message );
         }
-        
+
         if ( mechClass == NtlmMechanismHandler.class )
         {
             NtlmMechanismHandler ntlmHandler = ( NtlmMechanismHandler ) handler;
             ntlmHandler.setNtlmProviderFqcn( saslMechHandlerBean.getNtlmMechProvider() );
         }
-        
+
         return handler;
     }
-    
+
+
     /**
      * Creates a Authenticator from the configuration
      * 
      * @param authenticatorBean The created instance of authenticator
      * @return An instance of authenticator if the given authenticatorBean is not disabled
      */
-    public static Authenticator createAuthenticator( AuthenticatorBean authenticatorBean ) throws ConfigurationException
+    public static Authenticator createAuthenticator( AuthenticatorBean authenticatorBean )
+        throws ConfigurationException
     {
         if ( authenticatorBean.isDisabled() )
         {
             return null;
         }
-        
+
         Authenticator authenticator = null;
-        
-        if (authenticatorBean instanceof DelegatingAuthenticatorBean)
+
+        if ( authenticatorBean instanceof DelegatingAuthenticatorBean )
         {
             authenticator = new DelegatingAuthenticator();
-            ((DelegatingAuthenticator)authenticator).setDelegateHost( ((DelegatingAuthenticatorBean) authenticatorBean).getDelegateHost() );
-            ((DelegatingAuthenticator)authenticator).setDelegatePort( ((DelegatingAuthenticatorBean) authenticatorBean).getDelegatePort() );
+            ( ( DelegatingAuthenticator ) authenticator )
+                .setDelegateHost( ( ( DelegatingAuthenticatorBean ) authenticatorBean ).getDelegateHost() );
+            ( ( DelegatingAuthenticator ) authenticator )
+                .setDelegatePort( ( ( DelegatingAuthenticatorBean ) authenticatorBean ).getDelegatePort() );
         }
         else if ( authenticatorBean instanceof AuthenticatorImplBean )
         {
             String fqcn = ( ( AuthenticatorImplBean ) authenticatorBean ).getAuthenticatorClass();
-            
+
             try
             {
                 Class<?> authnImplClass = Class.forName( fqcn );
                 authenticator = ( Authenticator ) authnImplClass.newInstance();
             }
-            catch( Exception e )
+            catch ( Exception e )
             {
-                String errorMsg = "Failed to instantiate the configured authenticator " + authenticatorBean.getAuthenticatorId();
+                String errorMsg = "Failed to instantiate the configured authenticator "
+                    + authenticatorBean.getAuthenticatorId();
                 LOG.warn( errorMsg );
                 throw new ConfigurationException( errorMsg, e );
             }
         }
-        
+
         return authenticator;
     }
 
+
     /**
      * Creates a Transport from the configuration
      * 
@@ -486,7 +499,7 @@ public class ServiceBuilder
         {
             return null;
         }
-        
+
         Transport transport = null;
 
         if ( transportBean instanceof TcpTransportBean )
@@ -507,7 +520,7 @@ public class ServiceBuilder
         return transport;
     }
 
-    
+
     /**
      * Creates the array of transports read from the DIT
      * 
@@ -516,17 +529,18 @@ public class ServiceBuilder
      */
     public static Authenticator[] createAuthenticators( List<AuthenticatorBean> list ) throws ConfigurationException
     {
-        Authenticator[] authenticators = new Authenticator[ list.size() ];
+        Authenticator[] authenticators = new Authenticator[list.size()];
         int i = 0;
-        
+
         for ( AuthenticatorBean authenticatorBean : list )
         {
             authenticators[i++] = createAuthenticator( authenticatorBean );
         }
-        
+
         return authenticators;
     }
 
+
     /**
      * Creates the array of transports read from the DIT
      * 
@@ -536,7 +550,7 @@ public class ServiceBuilder
     public static Transport[] createTransports( TransportBean[] transportBeans )
     {
         List<Transport> transports = new ArrayList<Transport>();
-        
+
         for ( TransportBean transportBean : transportBeans )
         {
             if ( transportBean.isEnabled() )
@@ -544,9 +558,11 @@ public class ServiceBuilder
                 transports.add( createTransport( transportBean ) );
             }
         }
-        
+
         return transports.toArray( new Transport[transports.size()] );
     }
+
+
     /**
      * Helper method to create an Array of EncryptionTypes from an array of Strings
      */
@@ -556,18 +572,19 @@ public class ServiceBuilder
         {
             return new EncryptionType[0];
         }
-        
+
         EncryptionType[] types = new EncryptionType[encryptionTypes.size()];
         int pos = 0;
-        
+
         for ( String encryptionType : encryptionTypes )
         {
             types[pos++] = EncryptionType.getByName( encryptionType );
         }
-        
+
         return types;
     }
 
+
     /**
      * Instantiates a NtpServer based on the configuration present in the partition
      *
@@ -575,7 +592,8 @@ public class ServiceBuilder
      * @return Instance of NtpServer
      * @throws org.apache.directory.shared.ldap.model.exception.LdapException
      */
-    public static NtpServer createNtpServer( NtpServerBean ntpServerBean, DirectoryService directoryService ) throws LdapException
+    public static NtpServer createNtpServer( NtpServerBean ntpServerBean, DirectoryService directoryService )
+        throws LdapException
     {
         // Fist, do nothing if the NtpServer is disabled
         if ( ( ntpServerBean == null ) || ntpServerBean.isDisabled() )
@@ -584,14 +602,14 @@ public class ServiceBuilder
         }
 
         NtpServer ntpServer = new NtpServer();
-        
+
         // The service ID
         ntpServer.setServiceId( ntpServerBean.getServerId() );
-        
+
         // The transports
         Transport[] transports = createTransports( ntpServerBean.getTransports() );
         ntpServer.setTransports( transports );
-        
+
         return ntpServer;
     }
 
@@ -631,7 +649,8 @@ public class ServiceBuilder
      * @return Instance of KdcServer
      * @throws org.apache.directory.shared.ldap.model.exception.LdapException
      */
-    public static KdcServer createKdcServer( KdcServerBean kdcServerBean, DirectoryService directoryService ) throws LdapException
+    public static KdcServer createKdcServer( KdcServerBean kdcServerBean, DirectoryService directoryService )
+        throws LdapException
     {
         // Fist, do nothing if the KdcServer is disabled
         if ( ( kdcServerBean == null ) || kdcServerBean.isDisabled() )
@@ -640,69 +659,69 @@ public class ServiceBuilder
         }
 
         KdcServer kdcServer = new KdcServer();
-        
+
         kdcServer.setDirectoryService( directoryService );
         kdcServer.setEnabled( true );
-        
+
         kdcServer.setDirectoryService( directoryService );
-        
+
         // The ID
         kdcServer.setServiceId( kdcServerBean.getServerId() );
-        
+
         // AllowableClockSkew
         kdcServer.setAllowableClockSkew( kdcServerBean.getKrbAllowableClockSkew() );
-        
+
         // BodyChecksumVerified
         kdcServer.setBodyChecksumVerified( kdcServerBean.isKrbBodyChecksumVerified() );
-        
+
         // CatalogBased
         //kdcServer.setCatelogBased( kdcServerBean.is );
-        
+
         // EmptyAddressesAllowed
         kdcServer.setEmptyAddressesAllowed( kdcServerBean.isKrbEmptyAddressesAllowed() );
-        
+
         // EncryptionType
         EncryptionType[] encryptionTypes = createEncryptionTypes( kdcServerBean.getKrbEncryptionTypes() );
         kdcServer.setEncryptionTypes( encryptionTypes );
-        
+
         // ForwardableAllowed
         kdcServer.setForwardableAllowed( kdcServerBean.isKrbForwardableAllowed() );
-        
+
         // KdcPrincipal
         kdcServer.setKdcPrincipal( kdcServerBean.getKrbKdcPrincipal().toString() );
-        
+
         // MaximumRenewableLifetime
         kdcServer.setMaximumRenewableLifetime( kdcServerBean.getKrbMaximumRenewableLifetime() );
-        
+
         // MaximumTicketLifetime
         kdcServer.setMaximumTicketLifetime( kdcServerBean.getKrbMaximumTicketLifetime() );
-        
+
         // PaEncTimestampRequired
         kdcServer.setPaEncTimestampRequired( kdcServerBean.isKrbPaEncTimestampRequired() );
-        
+
         // PostdatedAllowed
         kdcServer.setPostdatedAllowed( kdcServerBean.isKrbPostdatedAllowed() );
-        
+
         // PrimaryRealm
         kdcServer.setPrimaryRealm( kdcServerBean.getKrbPrimaryRealm() );
-        
+
         // ProxiableAllowed
         kdcServer.setProxiableAllowed( kdcServerBean.isKrbProxiableAllowed() );
 
         // RenewableAllowed
         kdcServer.setRenewableAllowed( kdcServerBean.isKrbRenewableAllowed() );
-        
+
         // searchBaseDn
         kdcServer.setSearchBaseDn( kdcServerBean.getSearchBaseDn().getName() );
-        
+
         // The transports
         Transport[] transports = createTransports( kdcServerBean.getTransports() );
         kdcServer.setTransports( transports );
-        
+
         return kdcServer;
     }
-    
-    
+
+
     /**
      * Instantiates the HttpWebApps based on the configuration present in the partition
      *
@@ -710,7 +729,8 @@ public class ServiceBuilder
      * @return Instances of HttpWebAppBean
      * @throws LdapException
      */
-    public static Set<WebApp> createHttpWebApps( List<HttpWebAppBean> httpWebAppBeans, DirectoryService directoryService ) throws LdapException
+    public static Set<WebApp> createHttpWebApps( List<HttpWebAppBean> httpWebAppBeans, DirectoryService directoryService )
+        throws LdapException
     {
         Set<WebApp> webApps = new HashSet<WebApp>();
 
@@ -725,22 +745,22 @@ public class ServiceBuilder
             {
                 continue;
             }
-            
+
             WebApp webApp = new WebApp();
-            
+
             // HttpAppCtxPath
             webApp.setContextPath( httpWebAppBean.getHttpAppCtxPath() );
-            
+
             // HttpWarFile
             webApp.setWarFile( httpWebAppBean.getHttpWarFile() );
-            
+
             webApps.add( webApp );
         }
-        
+
         return webApps;
     }
-    
-    
+
+
     /**
      * Instantiates a HttpServer based on the configuration present in the partition
      *
@@ -748,7 +768,8 @@ public class ServiceBuilder
      * @return Instance of LdapServer
      * @throws LdapException
      */
-    public static HttpServer createHttpServer( HttpServerBean httpServerBean, DirectoryService directoryService ) throws LdapException
+    public static HttpServer createHttpServer( HttpServerBean httpServerBean, DirectoryService directoryService )
+        throws LdapException
     {
         // Fist, do nothing if the HttpServer is disabled
         if ( ( httpServerBean == null ) || httpServerBean.isDisabled() )
@@ -757,25 +778,25 @@ public class ServiceBuilder
         }
 
         HttpServer httpServer = new HttpServer();
-        
+
         // HttpConfFile
         httpServer.setConfFile( httpServerBean.getHttpConfFile() );
-        
+
         // The transports
         TransportBean[] transports = httpServerBean.getTransports();
-        
+
         for ( TransportBean transportBean : transports )
         {
             if ( transportBean.isDisabled() )
             {
                 continue;
             }
-            
+
             if ( transportBean instanceof TcpTransportBean )
             {
                 TcpTransport transport = new TcpTransport( transportBean.getSystemPort() );
                 transport.setAddress( transportBean.getTransportAddress() );
-                
+
                 if ( transportBean.getTransportId().equalsIgnoreCase( HttpServer.HTTP_TRANSPORT_ID ) )
                 {
                     httpServer.setHttpTransport( transport );
@@ -790,14 +811,14 @@ public class ServiceBuilder
                 }
             }
         }
-        
+
         // The webApps
         httpServer.setWebApps( createHttpWebApps( httpServerBean.getHttpWebApps(), directoryService ) );
-        
+
         return httpServer;
     }
-    
-    
+
+
     /**
      * Instantiates a ChangePasswordServer based on the configuration present in the partition
      *
@@ -859,7 +880,7 @@ public class ServiceBuilder
         return changePasswordServer;
     }
     */
-    
+
     /**
      * Instantiates a LdapServer based on the configuration present in the partition
      *
@@ -867,7 +888,8 @@ public class ServiceBuilder
      * @return Instance of LdapServer
      * @throws LdapException
      */
-    public static LdapServer createLdapServer( LdapServerBean ldapServerBean, DirectoryService directoryService ) throws LdapException
+    public static LdapServer createLdapServer( LdapServerBean ldapServerBean, DirectoryService directoryService )
+        throws LdapException
     {
         // Fist, do nothing if the LdapServer is disabled
         if ( ( ldapServerBean == null ) || ldapServerBean.isDisabled() )
@@ -876,10 +898,10 @@ public class ServiceBuilder
         }
 
         LdapServer ldapServer = new LdapServer();
-        
+
         ldapServer.setDirectoryService( directoryService );
         ldapServer.setEnabled( true );
-        
+
         // The ID
         ldapServer.setServiceId( ldapServerBean.getServerId() );
 
@@ -888,10 +910,10 @@ public class ServiceBuilder
 
         // KeyStore
         ldapServer.setKeystoreFile( ldapServerBean.getLdapServerKeystoreFile() );
-            
+
         // Certificate password
         ldapServer.setCertificatePassword( ldapServerBean.getLdapServerCertificatePassword() );
-        
+
         // ConfidentialityRequired
         ldapServer.setConfidentialityRequired( ldapServerBean.isLdapServerConfidentialityRequired() );
 
@@ -900,16 +922,16 @@ public class ServiceBuilder
 
         // Max time limit
         ldapServer.setMaxTimeLimit( ldapServerBean.getLdapServerMaxTimeLimit() );
-        
+
         // Sasl Host
         ldapServer.setSaslHost( ldapServerBean.getLdapServerSaslHost() );
-        
+
         // Sasl Principal
         ldapServer.setSaslPrincipal( ldapServerBean.getLdapServerSaslPrincipal() );
-        
+
         // Sasl realm
         ldapServer.setSaslRealms( ldapServerBean.getLdapServerSaslRealms() );
-        
+
         // The transports
         Transport[] transports = createTransports( ldapServerBean.getTransports() );
         ldapServer.setTransports( transports );
@@ -923,7 +945,7 @@ public class ServiceBuilder
                 ldapServer.addSaslMechanismHandler( mechanism, createSaslMechHandler( saslMechHandlerBean ) );
             }
         }
-        
+
         // ExtendedOpHandlers
         for ( ExtendedOpHandlerBean extendedpHandlerBean : ldapServerBean.getExtendedOps() )
         {
@@ -947,7 +969,7 @@ public class ServiceBuilder
 
         // ReplReqHandler
         String fqcn = ldapServerBean.getReplReqHandler();
-        
+
         if ( fqcn != null )
         {
             try
@@ -956,21 +978,21 @@ public class ServiceBuilder
                 ReplicationRequestHandler rp = ( ReplicationRequestHandler ) replProvImplClz.newInstance();
                 ldapServer.setReplicationReqHandler( rp );
             }
-            catch( Exception e )
+            catch ( Exception e )
             {
                 String message = "Failed to load and instantiate ReplicationRequestHandler implementation : " + fqcn;
                 LOG.error( message );
                 throw new ConfigurationException( message );
             }
-            
+
         }
-        
+
         ldapServer.setReplConsumers( createReplConsumers( ldapServerBean.getReplConsumers() ) );
-        
+
         return ldapServer;
     }
-    
-    
+
+
     /**
      * instantiate the ReplicationConsumers based on the configuration present in ReplConsumerBeans
      * 
@@ -978,26 +1000,27 @@ public class ServiceBuilder
      * @return a list of ReplicationConsumer instances
      * @throws ConfigurationException
      */
-    public static List<ReplicationConsumer> createReplConsumers( List<ReplConsumerBean> replConsumerBeans ) throws ConfigurationException
+    public static List<ReplicationConsumer> createReplConsumers( List<ReplConsumerBean> replConsumerBeans )
+        throws ConfigurationException
     {
         List<ReplicationConsumer> lst = new ArrayList<ReplicationConsumer>();
 
-        if( replConsumerBeans == null )
+        if ( replConsumerBeans == null )
         {
             return lst;
         }
-        
+
         for ( ReplConsumerBean replBean : replConsumerBeans )
         {
             String className = replBean.getReplConsumerImpl();
-            
+
             ReplicationConsumer consumer = null;
             Class<?> consumerClass = null;
             SyncreplConfiguration config = null;
-            
+
             try
             {
-                if( className == null )
+                if ( className == null )
                 {
                     consumerClass = ReplicationConsumerImpl.class;
                 }
@@ -1005,9 +1028,9 @@ public class ServiceBuilder
                 {
                     consumerClass = Class.forName( className );
                 }
-                
+
                 consumer = ( ReplicationConsumer ) consumerClass.newInstance();
-                
+
                 // we don't support any other configuration impls atm, but this configuration should suffice for many needs
                 config = new SyncreplConfiguration();
 
@@ -1018,39 +1041,40 @@ public class ServiceBuilder
                 config.setAttributes( replBean.getReplAttributes().toArray( new String[0] ) );
                 config.setRefreshInterval( replBean.getReplRefreshInterval() );
                 config.setRefreshNPersist( replBean.isReplRefreshNPersist() );
-                
+
                 int scope = SearchScope.getSearchScope( replBean.getReplSearchScope() );
                 config.setSearchScope( SearchScope.getSearchScope( scope ) );
-                
+
                 config.setFilter( replBean.getReplSearchFilter() );
                 config.setSearchTimeout( replBean.getReplSearchTimeOut() );
                 config.setReplUserDn( replBean.getReplUserDn() );
                 config.setReplUserPassword( replBean.getReplUserPassword() );
-                
+
                 config.setUseTls( replBean.isReplUseTls() );
                 config.setStrictCertVerification( replBean.isReplStrictCertValidation() );
-                
+
                 config.setConfigEntryDn( replBean.getDn() );
-                
+
                 if ( replBean.getReplPeerCertificate() != null )
                 {
-                    ReplicationTrustManager.addCertificate( replBean.getReplConsumerId(), replBean.getReplPeerCertificate() );
+                    ReplicationTrustManager.addCertificate( replBean.getReplConsumerId(),
+                        replBean.getReplPeerCertificate() );
                 }
-                
+
                 consumer.setConfig( config );
-                
+
                 lst.add( consumer );
             }
-            catch( Exception e )
+            catch ( Exception e )
             {
                 throw new ConfigurationException( "cannot configure the replication consumer with FQCN " + className, e );
             }
         }
-        
+
         return lst;
     }
-    
-    
+
+
     /**
      * Create a new instance of a JdbmIndex from an instance of JdbmIndexBean
      * 
@@ -1058,29 +1082,30 @@ public class ServiceBuilder
      * @return An JdbmIndex instance
      * @throws Exception If the instance cannot be created
      */
-    public static JdbmIndex<?, Entry> createJdbmIndex( JdbmPartition partition, JdbmIndexBean<String, Entry> jdbmIndexBean, DirectoryService directoryService )
+    public static JdbmIndex<?, Entry> createJdbmIndex( JdbmPartition partition,
+        JdbmIndexBean<String, Entry> jdbmIndexBean, DirectoryService directoryService )
     {
         if ( ( jdbmIndexBean == null ) || jdbmIndexBean.isDisabled() )
         {
             return null;
         }
-        
+
         JdbmIndex<String, Entry> index = new JdbmIndex<String, Entry>();
-        
+
         index.setAttributeId( jdbmIndexBean.getIndexAttributeId() );
         index.setCacheSize( jdbmIndexBean.getIndexCacheSize() );
         index.setNumDupLimit( jdbmIndexBean.getIndexNumDupLimit() );
-        
+
         String indexFileName = jdbmIndexBean.getIndexFileName();
-        
+
         if ( indexFileName == null )
         {
             indexFileName = jdbmIndexBean.getIndexAttributeId();
         }
-            
+
         // Find the OID for this index
         SchemaManager schemaManager = directoryService.getSchemaManager();
-        
+
         try
         {
             AttributeType indexAT = schemaManager.lookupAttributeTypeRegistry( indexFileName );
@@ -1090,7 +1115,7 @@ public class ServiceBuilder
         {
             // Not found ? We will use the index file name
         }
-        
+
         if ( jdbmIndexBean.getIndexWorkingDir() != null )
         {
             index.setWkDirPath( new File( jdbmIndexBean.getIndexWorkingDir() ).toURI() );
@@ -1100,15 +1125,16 @@ public class ServiceBuilder
             // Set the Partition working dir as a default
             index.setWkDirPath( partition.getPartitionPath() );
         }
-                
+
         return index;
     }
 
-    
+
     /**
      * Create the list of Index from the configuration
      */
-    private static Set<Index<?, Entry, Long>> createJdbmIndexes( JdbmPartition partition, List<IndexBean> indexesBeans, DirectoryService directoryService ) //throws Exception
+    private static Set<Index<?, Entry, Long>> createJdbmIndexes( JdbmPartition partition, List<IndexBean> indexesBeans,
+        DirectoryService directoryService ) //throws Exception
     {
         Set<Index<?, Entry, Long>> indexes = new HashSet<Index<?, Entry, Long>>();
 
@@ -1116,7 +1142,7 @@ public class ServiceBuilder
         {
             if ( indexBean.isEnabled() && ( indexBean instanceof JdbmIndexBean ) )
             {
-                indexes.add( createJdbmIndex( partition, (JdbmIndexBean)indexBean, directoryService ) );
+                indexes.add( createJdbmIndex( partition, ( JdbmIndexBean ) indexBean, directoryService ) );
             }
         }
 
@@ -1132,21 +1158,23 @@ public class ServiceBuilder
      * @throws LdapInvalidDnException
      * @throws Exception If the instance cannot be created
      */
-    public static JdbmPartition createJdbmPartition( DirectoryService directoryService, JdbmPartitionBean jdbmPartitionBean ) throws ConfigurationException
+    public static JdbmPartition createJdbmPartition( DirectoryService directoryService,
+        JdbmPartitionBean jdbmPartitionBean ) throws ConfigurationException
     {
         if ( ( jdbmPartitionBean == null ) || jdbmPartitionBean.isDisabled() )
         {
             return null;
         }
-        
+
         JdbmPartition jdbmPartition = new JdbmPartition( directoryService.getSchemaManager() );
-        
+
         jdbmPartition.setCacheSize( jdbmPartitionBean.getPartitionCacheSize() );
         jdbmPartition.setId( jdbmPartitionBean.getPartitionId() );
         jdbmPartition.setOptimizerEnabled( jdbmPartitionBean.isJdbmPartitionOptimizerEnabled() );
-        File partitionPath = new File( directoryService.getInstanceLayout().getPartitionsDirectory(), jdbmPartitionBean.getPartitionId() );
+        File partitionPath = new File( directoryService.getInstanceLayout().getPartitionsDirectory(),
+            jdbmPartitionBean.getPartitionId() );
         jdbmPartition.setPartitionPath( partitionPath.toURI() );
-        
+
         try
         {
             jdbmPartition.setSuffixDn( jdbmPartitionBean.getPartitionSuffix() );
@@ -1157,23 +1185,24 @@ public class ServiceBuilder
             LOG.error( message );
             throw new ConfigurationException( message );
         }
-        
+
         jdbmPartition.setSyncOnWrite( jdbmPartitionBean.isPartitionSyncOnWrite() );
-        jdbmPartition.setIndexedAttributes( createJdbmIndexes( jdbmPartition, jdbmPartitionBean.getIndexes(), directoryService ) );
-        
+        jdbmPartition.setIndexedAttributes( createJdbmIndexes( jdbmPartition, jdbmPartitionBean.getIndexes(),
+            directoryService ) );
+
         String contextEntry = jdbmPartitionBean.getContextEntry();
-        
+
         if ( contextEntry != null )
         {
             try
             {
                 // Replace '\n' to real LF
                 String entryStr = contextEntry.replaceAll( "\\\\n", "\n" );
-                
+
                 LdifReader ldifReader = new LdifReader();
-                
+
                 List<LdifEntry> entries = ldifReader.parseLdif( entryStr );
-                
+
                 if ( ( entries != null ) && ( entries.size() > 0 ) )
                 {
                     entries.get( 0 );
@@ -1186,11 +1215,11 @@ public class ServiceBuilder
                 throw new ConfigurationException( message );
             }
         }
-        
+
         return jdbmPartition;
     }
-    
-    
+
+
     /**
      * Create the a Partition instantiated from the configuration
      * 
@@ -1198,23 +1227,25 @@ public class ServiceBuilder
      * @return The instantiated Partition
      * @throws ConfigurationException If we cannot process the Partition
      */
-    public static Partition createPartition( DirectoryService directoryService, PartitionBean partitionBean ) throws ConfigurationException
+    public static Partition createPartition( DirectoryService directoryService, PartitionBean partitionBean )
+        throws ConfigurationException
     {
         if ( ( partitionBean == null ) || partitionBean.isDisabled() )
         {
             return null;
         }
-        
+
         if ( partitionBean instanceof JdbmPartitionBean )
         {
-            return createJdbmPartition( directoryService, (JdbmPartitionBean)partitionBean );
+            return createJdbmPartition( directoryService, ( JdbmPartitionBean ) partitionBean );
         }
         else
         {
             return null;
         }
     }
-    
+
+
     /**
      * Create the set of Partitions instantiated from the configuration
      * 
@@ -1222,29 +1253,30 @@ public class ServiceBuilder
      * @return A Map of all the instantiated partitions
      * @throws ConfigurationException If we cannot process some Partition
      */
-    public static Map<String, Partition> createPartitions( DirectoryService directoryService, List<PartitionBean> partitionBeans ) throws ConfigurationException
+    public static Map<String, Partition> createPartitions( DirectoryService directoryService,
+        List<PartitionBean> partitionBeans ) throws ConfigurationException
     {
         Map<String, Partition> partitions = new HashMap<String, Partition>( partitionBeans.size() );
-        
+
         for ( PartitionBean partitionBean : partitionBeans )
         {
             if ( partitionBean.isDisabled() )
             {
                 continue;
             }
-            
+
             Partition partition = createPartition( directoryService, partitionBean );
-            
+
             if ( partition != null )
             {
                 partitions.put( partitionBean.getPartitionId(), partition );
             }
         }
-        
+
         return partitions;
     }
 
-    
+
     /**
      * Instantiates a DirectoryService based on the configuration present in the partition
      *
@@ -1253,17 +1285,18 @@ public class ServiceBuilder
      * @return An instance of DirectoryService
      * @throws Exception
      */
-    public static DirectoryService createDirectoryService( DirectoryServiceBean directoryServiceBean, InstanceLayout instanceLayout, SchemaManager schemaManager ) throws Exception
+    public static DirectoryService createDirectoryService( DirectoryServiceBean directoryServiceBean,
+        InstanceLayout instanceLayout, SchemaManager schemaManager ) throws Exception
     {
         DirectoryService directoryService = new DefaultDirectoryService();
-        
+
         // The schemaManager
         directoryService.setSchemaManager( schemaManager );
 
         // MUST attributes
         // DirectoryService ID
         directoryService.setInstanceId( directoryServiceBean.getDirectoryServiceId() );
-        
+
         // Replica ID
         directoryService.setReplicaId( directoryServiceBean.getDsReplicaId() );
 
@@ -1273,7 +1306,7 @@ public class ServiceBuilder
         // Interceptors
         List<Interceptor> interceptors = createInterceptors( directoryServiceBean.getInterceptors() );
         directoryService.setInterceptors( interceptors );
-        
+
         // Partitions
         Map<String, Partition> partitions = createPartitions( directoryService, directoryServiceBean.getPartitions() );
 
@@ -1290,32 +1323,32 @@ public class ServiceBuilder
         // MAY attributes
         // AccessControlEnabled
         directoryService.setAccessControlEnabled( directoryServiceBean.isDsAccessControlEnabled() );
-        
+
         // AllowAnonymousAccess
         directoryService.setAllowAnonymousAccess( directoryServiceBean.isDsAllowAnonymousAccess() );
-        
+
         // ChangeLog
         ChangeLog cl = createChangeLog( directoryServiceBean.getChangeLog() );
-        
+
         if ( cl != null )
         {
             directoryService.setChangeLog( cl );
         }
-        
+
         // DenormalizedOpAttrsEnabled
         directoryService.setDenormalizeOpAttrsEnabled( directoryServiceBean.isDsDenormalizeOpAttrsEnabled() );
-        
+
         // Journal
         Journal journal = createJournal( directoryServiceBean.getJournal() );
-        
+
         if ( journal != null )
         {
             directoryService.setJournal( journal );
         }
-        
+
         // MaxPDUSize
         directoryService.setMaxPDUSize( directoryServiceBean.getDsMaxPDUSize() );
-        
+
         // PasswordHidden
         directoryService.setPasswordHidden( directoryServiceBean.isDsPasswordHidden() );
 
@@ -1324,12 +1357,12 @@ public class ServiceBuilder
 
         // testEntries
         String entryFilePath = directoryServiceBean.getDsTestEntries();
-        
+
         if ( entryFilePath != null )
         {
             directoryService.setTestEntries( readTestEntries( entryFilePath ) );
         }
-        
+
         // Enabled
         if ( !directoryServiceBean.isEnabled() )
         {

Modified: directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/ApacheDsService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/ApacheDsService.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/ApacheDsService.java (original)
+++ directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/ApacheDsService.java Tue Jan 24 16:27:18 2012
@@ -154,7 +154,7 @@ public class ApacheDsService
             LOG.info( "partition directory doesn't exist, creating {}", partitionsDir.getAbsolutePath() );
             if ( !partitionsDir.mkdirs() )
             {
-                throw new IOException(I18n.err( I18n.ERR_112_COULD_NOT_CREATE_DIRECORY, partitionsDir ) );
+                throw new IOException( I18n.err( I18n.ERR_112_COULD_NOT_CREATE_DIRECORY, partitionsDir ) );
             }
         }
 

Modified: directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/InstallationLayout.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/InstallationLayout.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/InstallationLayout.java (original)
+++ directory/apacheds/trunk/service-osgi/src/main/java/org/apache/directory/server/InstallationLayout.java Tue Jan 24 16:27:18 2012
@@ -72,7 +72,7 @@ public class InstallationLayout extends 
                 getBinDirectory(),
                 getConfDirectory(),
                 getLibDirectory()
-            };
+        };
         setRequiredDirectories( requiredDirectories );
 
         // The required files
@@ -81,7 +81,7 @@ public class InstallationLayout extends 
                 getScriptFile(),
                 getWrapperFile(),
                 getWrapperConfigurationFile()
-            };
+        };
         setRequiredFiles( requiredFiles );
     }
 

Modified: directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/AbstractLdapTestUnit.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/AbstractLdapTestUnit.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/AbstractLdapTestUnit.java (original)
+++ directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/AbstractLdapTestUnit.java Tue Jan 24 16:27:18 2012
@@ -43,9 +43,8 @@ public abstract class AbstractLdapTestUn
 
     /** A flag set if the test is run in a suite */
     public static boolean isRunInSuite;
-    
 
-    
+
     public static DirectoryService getService()
     {
         return service;

Modified: directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java (original)
+++ directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkRunner.java Tue Jan 24 16:27:18 2012
@@ -87,31 +87,31 @@ public class FrameworkRunner extends Blo
     /**
      * Initialize the codec service
      */
-    static 
+    static
     {
         // Load the extension points
-        System.setProperty( StandaloneLdapApiService.DEFAULT_CONTROLS_LIST, 
+        System.setProperty( StandaloneLdapApiService.DEFAULT_CONTROLS_LIST,
             "org.apache.directory.shared.ldap.codec.controls.cascade.CascadeFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.manageDsaIT.ManageDsaITFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.entryChange.EntryChangeFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.pagedSearch.PagedResultsFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.persistentSearch.PersistentSearchFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.subentries.SubentriesFactory" );
+                "org.apache.directory.shared.ldap.codec.controls.manageDsaIT.ManageDsaITFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.entryChange.EntryChangeFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.pagedSearch.PagedResultsFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.persistentSearch.PersistentSearchFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.subentries.SubentriesFactory" );
 
-        System.setProperty( StandaloneLdapApiService.EXTRA_CONTROLS_LIST, 
+        System.setProperty( StandaloneLdapApiService.EXTRA_CONTROLS_LIST,
             "org.apache.directory.shared.ldap.extras.controls.ppolicy_impl.PasswordPolicyFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncDoneValueFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncInfoValueFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncRequestValueFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncStateValueFactory" );
-        
-        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_REQUESTS_LIST, 
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncDoneValueFactory," +
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncInfoValueFactory," +
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncRequestValueFactory," +
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncStateValueFactory" );
+
+        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_REQUESTS_LIST,
             "org.apache.directory.shared.ldap.extras.extended.ads_impl.cancel.CancelFactory," +
-            "org.apache.directory.shared.ldap.extras.extended.ads_impl.certGeneration.CertGenerationFactory," +
-            "org.apache.directory.shared.ldap.extras.extended.ads_impl.gracefulShutdown.GracefulShutdownFactory," +
-            "org.apache.directory.shared.ldap.extras.extended.ads_impl.storedProcedure.StoredProcedureFactory" );
+                "org.apache.directory.shared.ldap.extras.extended.ads_impl.certGeneration.CertGenerationFactory," +
+                "org.apache.directory.shared.ldap.extras.extended.ads_impl.gracefulShutdown.GracefulShutdownFactory," +
+                "org.apache.directory.shared.ldap.extras.extended.ads_impl.storedProcedure.StoredProcedureFactory" );
 
-        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_RESPONSES_LIST, 
+        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_RESPONSES_LIST,
             "org.apache.directory.shared.ldap.extras.extended.ads_impl.gracefulDisconnect.GracefulDisconnectFactory" );
     }
 
@@ -221,13 +221,13 @@ public class FrameworkRunner extends Blo
             else if ( ( suite != null ) && ( suite.getLdapServer() != null ) )
             {
                 classLdapServer = suite.getLdapServer();
-                
+
                 // set directoryService only if there is no class level DS
                 if ( directoryService == null )
                 {
                     directoryService = classLdapServer.getDirectoryService();
                 }
-                
+
                 // no need to inject the LDIF data that would have been done above
                 // if ApplyLdifs is present
             }
@@ -319,7 +319,7 @@ public class FrameworkRunner extends Blo
                 }
             }
         }
-        
+
         return minPort;
     }
 
@@ -435,14 +435,16 @@ public class FrameworkRunner extends Blo
 
             // At this point, we know which service to use.
             // Inject it into the class
-            Method setService = getTestClass().getJavaClass().getMethod( SET_SERVICE_METHOD_NAME, DirectoryService.class );
+            Method setService = getTestClass().getJavaClass().getMethod( SET_SERVICE_METHOD_NAME,
+                DirectoryService.class );
             setService.invoke( getTestClass().getJavaClass(), directoryService );
 
             // if we run this class in a suite, tell it to the test
             Field runInSuiteField = getTestClass().getJavaClass().getField( IS_RUN_IN_SUITE_FIELD_NAME );
             runInSuiteField.set( getTestClass().getJavaClass(), suite != null );
 
-            Method setLdapServer = getTestClass().getJavaClass().getMethod( SET_LDAP_SERVER_METHOD_NAME, LdapServer.class );
+            Method setLdapServer = getTestClass().getJavaClass().getMethod( SET_LDAP_SERVER_METHOD_NAME,
+                LdapServer.class );
             Method setKdcServer = getTestClass().getJavaClass().getMethod( SET_KDC_SERVER_METHOD_NAME, KdcServer.class );
 
             DirectoryService oldLdapServerDirService = null;
@@ -454,7 +456,7 @@ public class FrameworkRunner extends Blo
                 methodLdapServer.setDirectoryService( directoryService );
 
                 setLdapServer.invoke( getTestClass().getJavaClass(), methodLdapServer );
-            }    
+            }
             else if ( classLdapServer != null )
             {
                 oldLdapServerDirService = classLdapServer.getDirectoryService();
@@ -494,12 +496,12 @@ public class FrameworkRunner extends Blo
             {
                 classLdapServer.setDirectoryService( oldLdapServerDirService );
             }
-            
+
             if ( oldKdcServerDirService != null )
             {
                 classKdcServer.setDirectoryService( oldKdcServerDirService );
             }
-            
+
             // Cleanup the methodDS if it has been created
             if ( methodDS != null )
             {

Modified: directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java (original)
+++ directory/apacheds/trunk/test-framework/src/main/java/org/apache/directory/server/core/integ/FrameworkSuite.java Tue Jan 24 16:27:18 2012
@@ -53,7 +53,7 @@ public class FrameworkSuite extends Suit
 
     /** The suite DS, if any */
     private DirectoryService directoryService;
-    
+
     /** The LdapServerBuilder for this class, if any */
     private CreateLdapServer ldapServerBuilder;
 
@@ -63,34 +63,35 @@ public class FrameworkSuite extends Suit
     /**
      * Initialize the codec service
      */
-    static 
+    static
     {
         // Load the extension points
-        System.setProperty( StandaloneLdapApiService.DEFAULT_CONTROLS_LIST, 
+        System.setProperty( StandaloneLdapApiService.DEFAULT_CONTROLS_LIST,
             "org.apache.directory.shared.ldap.codec.controls.cascade.CascadeFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.manageDsaIT.ManageDsaITFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.entryChange.EntryChangeFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.pagedSearch.PagedResultsFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.persistentSearch.PersistentSearchFactory," +
-            "org.apache.directory.shared.ldap.codec.controls.search.subentries.SubentriesFactory" );
+                "org.apache.directory.shared.ldap.codec.controls.manageDsaIT.ManageDsaITFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.entryChange.EntryChangeFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.pagedSearch.PagedResultsFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.persistentSearch.PersistentSearchFactory," +
+                "org.apache.directory.shared.ldap.codec.controls.search.subentries.SubentriesFactory" );
 
-        System.setProperty( StandaloneLdapApiService.EXTRA_CONTROLS_LIST, 
+        System.setProperty( StandaloneLdapApiService.EXTRA_CONTROLS_LIST,
             "org.apache.directory.shared.ldap.extras.controls.ppolicy_impl.PasswordPolicyFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncDoneValueFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncInfoValueFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncRequestValueFactory," +
-            "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncStateValueFactory" );
-        
-        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_REQUESTS_LIST, 
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncDoneValueFactory," +
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncInfoValueFactory," +
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncRequestValueFactory," +
+                "org.apache.directory.shared.ldap.extras.controls.syncrepl_impl.SyncStateValueFactory" );
+
+        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_REQUESTS_LIST,
             "org.apache.directory.shared.ldap.extras.extended.ads_impl.cancel.CancelFactory," +
-            "org.apache.directory.shared.ldap.extras.extended.ads_impl.certGeneration.CertGenerationFactory," +
-            "org.apache.directory.shared.ldap.extras.extended.ads_impl.gracefulShutdown.GracefulShutdownFactory," +
-            "org.apache.directory.shared.ldap.extras.extended.ads_impl.storedProcedure.StoredProcedureFactory" );
+                "org.apache.directory.shared.ldap.extras.extended.ads_impl.certGeneration.CertGenerationFactory," +
+                "org.apache.directory.shared.ldap.extras.extended.ads_impl.gracefulShutdown.GracefulShutdownFactory," +
+                "org.apache.directory.shared.ldap.extras.extended.ads_impl.storedProcedure.StoredProcedureFactory" );
 
-        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_RESPONSES_LIST, 
+        System.setProperty( StandaloneLdapApiService.DEFAULT_EXTENDED_OPERATION_RESPONSES_LIST,
             "org.apache.directory.shared.ldap.extras.extended.ads_impl.gracefulDisconnect.GracefulDisconnectFactory" );
     }
 
+
     /**
      * Creates a new instance of FrameworkSuite.
      */
@@ -98,8 +99,8 @@ public class FrameworkSuite extends Suit
     {
         super( clazz, builder );
     }
-    
-    
+
+
     /**
      * Start and initialize the DS
      */
@@ -107,15 +108,15 @@ public class FrameworkSuite extends Suit
     {
         // Initialize and start the DS before running any test, if we have a DS annotation
         directoryService = DSAnnotationProcessor.getDirectoryService( description );
-        
+
         // and inject LDIFs if needed
         if ( directoryService != null )
         {
             DSAnnotationProcessor.applyLdifs( description, directoryService );
         }
     }
-    
-    
+
+
     /**
      * Stop and clean the DS
      */
@@ -138,13 +139,13 @@ public class FrameworkSuite extends Suit
         }
     }
 
-    
+
     private void startLdapServer( Description description ) throws Exception
     {
         ldapServer = ServerAnnotationProcessor.createLdapServer( description, directoryService );
     }
-    
-    
+
+
     private void stopLdapServer()
     {
         if ( ( ldapServer != null ) && ( ldapServer.isStarted() ) )
@@ -152,8 +153,8 @@ public class FrameworkSuite extends Suit
             ldapServer.stop();
         }
     }
-    
-    
+
+
     /**
      * {@inheritDoc}
      */
@@ -169,22 +170,22 @@ public class FrameworkSuite extends Suit
 
             // Create and initialize the Suite DS
             startDS( getDescription() );
-            
+
             // create and initialize the suite LdapServer
             startLdapServer( getDescription() );
-            
+
             // Run the suite
             super.run( notifier );
-            
+
             // Stop the LdapServer
             stopLdapServer();
-            
+
             // last, stop the DS if we have one
             stopDS();
         }
         catch ( Exception e )
         {
-            notifier.fireTestFailure(new Failure(getDescription(), e));
+            notifier.fireTestFailure( new Failure( getDescription(), e ) );
         }
         finally
         {
@@ -195,6 +196,7 @@ public class FrameworkSuite extends Suit
         }
     }
 
+
     /**
      * {@inheritDoc}
      */
@@ -202,10 +204,10 @@ public class FrameworkSuite extends Suit
     protected void runChild( Runner runner, RunNotifier notifier )
     {
         // Store the suite into the class we will run
-        if( runner instanceof FrameworkRunner )
+        if ( runner instanceof FrameworkRunner )
         {
             ( ( FrameworkRunner ) runner ).setSuite( this );
-            
+
             // Now, call the class containing the tests
             super.runChild( runner, notifier );
         }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassA.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassA.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassA.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassA.java Tue Jan 24 16:27:18 2012
@@ -30,61 +30,61 @@ import org.junit.runner.RunWith;
 
 
 @RunWith(FrameworkRunner.class)
-@CreateDS( name="ClassDS" )
+@CreateDS(name = "ClassDS")
 @ApplyLdifs(
     {
-        "dn: cn=testClassA,ou=system", 
-        "objectClass: person", 
-        "cn: testClassA", 
+        "dn: cn=testClassA,ou=system",
+        "objectClass: person",
+        "cn: testClassA",
         "sn: sn_testClassA",
-        
-        "dn: cn=testClassA2,ou=system", 
-        "objectClass: person", 
-        "cn: testClassA2", 
+
+        "dn: cn=testClassA2,ou=system",
+        "objectClass: person",
+        "cn: testClassA2",
         "sn: sn_testClassA2"
-        
-    })
+
+})
 public class TestClassA extends AbstractLdapTestUnit
 {
-    @Test
-    @CreateDS( name="testDS" )
-    @ApplyLdifs(
-        {
-            "dn: cn=testMethodA,ou=system", 
-            "objectClass: person",
-            "cn: testMethodA", 
-            "sn: sn_testMethodA" 
-        })
-    public void testWithFactoryAnnotation() throws Exception
+@Test
+@CreateDS(name = "testDS")
+@ApplyLdifs(
+    {
+        "dn: cn=testMethodA,ou=system",
+        "objectClass: person",
+        "cn: testMethodA",
+        "sn: sn_testMethodA"
+})
+public void testWithFactoryAnnotation() throws Exception
+{
+    if ( isRunInSuite )
     {
-        if ( isRunInSuite )
-        {
-            assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
-        }
-        
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassA,ou=system" ) ) );
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testMethodA,ou=system" ) ) );
+        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
     }
 
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassA,ou=system" ) ) );
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testMethodA,ou=system" ) ) );
+}
+
 
-    @Test
-    @ApplyLdifs(
-        {
-            "dn: cn=testMethodWithApplyLdif,ou=system", 
-            "objectClass: person", 
-            "cn: testMethodWithApplyLdif", 
-            "sn: sn_testMethodWithApplyLdif" 
-        })
-    public void testWithoutFactoryAnnotation() throws Exception
+@Test
+@ApplyLdifs(
+    {
+        "dn: cn=testMethodWithApplyLdif,ou=system",
+        "objectClass: person",
+        "cn: testMethodWithApplyLdif",
+        "sn: sn_testMethodWithApplyLdif"
+})
+public void testWithoutFactoryAnnotation() throws Exception
+{
+    if ( isRunInSuite )
     {
-        if ( isRunInSuite )
-        {
-            assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
-        }
-
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassA,ou=system" ) ) );
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassA2,ou=system" ) ) );
-        assertFalse( getService().getAdminSession().exists( new Dn( "cn=testMethodA,ou=system" ) ) );
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testMethodWithApplyLdif,ou=system" ) ) );
+        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
     }
+
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassA,ou=system" ) ) );
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassA2,ou=system" ) ) );
+    assertFalse( getService().getAdminSession().exists( new Dn( "cn=testMethodA,ou=system" ) ) );
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testMethodWithApplyLdif,ou=system" ) ) );
+}
 }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassB.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassB.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassB.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassB.java Tue Jan 24 16:27:18 2012
@@ -27,42 +27,43 @@ import org.apache.directory.shared.ldap.
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
-@RunWith( FrameworkRunner.class )
+
+@RunWith(FrameworkRunner.class)
 @ApplyLdifs(
     {
-        "dn: cn=testClassB,ou=system", 
-        "objectClass: person", 
-        "cn: testClassB", 
+        "dn: cn=testClassB,ou=system",
+        "objectClass: person",
+        "cn: testClassB",
         "sn: sn_testClassB"
-    })
+})
 public class TestClassB extends AbstractLdapTestUnit
 {
 
-    @Test
-    @CreateDS( name="testDS" )
-    public void testWithFactoryAnnotation() throws Exception
+@Test
+@CreateDS(name = "testDS")
+public void testWithFactoryAnnotation() throws Exception
+{
+    if ( isRunInSuite )
     {
-        if ( isRunInSuite )
-        {
-            assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
-        }
-
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassB,ou=system" ) ) );
+        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
     }
-    
-    
-    @Test
-    public void testWithoutFactoryAnnotation() throws Exception
-    {
-        // this assertion will only work if ran as part of TestSuite
-        // commenting this to make maven report test success, uncomment in an IDE
-        // while running the TestSuite
-        // assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
-        if ( isRunInSuite )
-        {
-            assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
-        }
 
-        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassB,ou=system" ) ) );
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassB,ou=system" ) ) );
+}
+
+
+@Test
+public void testWithoutFactoryAnnotation() throws Exception
+{
+    // this assertion will only work if ran as part of TestSuite
+    // commenting this to make maven report test success, uncomment in an IDE
+    // while running the TestSuite
+    // assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
+    if ( isRunInSuite )
+    {
+        assertTrue( getService().getAdminSession().exists( new Dn( "cn=testSuite,ou=system" ) ) );
     }
+
+    assertTrue( getService().getAdminSession().exists( new Dn( "cn=testClassB,ou=system" ) ) );
+}
 }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassC.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassC.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassC.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassC.java Tue Jan 24 16:27:18 2012
@@ -27,7 +27,8 @@ import org.apache.directory.shared.ldap.
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
-@RunWith( FrameworkRunner.class )
+
+@RunWith(FrameworkRunner.class)
 public class TestClassC extends AbstractLdapTestUnit
 {
     @Test
@@ -39,15 +40,15 @@ public class TestClassC extends Abstract
         }
 
         assertFalse( getService().getAdminSession().exists( new Dn( "cn=testClassC,ou=system" ) ) );
-        
+
         // the below Dn will be injected in TestClassB when ran as suite, but that Dn
         // shouldn't be present in the suite level DS cause of revert operation
         assertFalse( getService().getAdminSession().exists( new Dn( "cn=testClassB,ou=system" ) ) );
     }
-    
-    
+
+
     @Test
-    @ApplyLdifFiles( "test-entry.ldif" )
+    @ApplyLdifFiles("test-entry.ldif")
     public void testWithApplyLdifFiles() throws Exception
     {
         assertTrue( getService().getAdminSession().exists( new Dn( "cn=testPerson1,ou=system" ) ) );

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassServer.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassServer.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestClassServer.java Tue Jan 24 16:27:18 2012
@@ -18,6 +18,7 @@
  */
 package org.apache.directory.server.core.integ;
 
+
 import static org.junit.Assert.assertTrue;
 
 import org.apache.directory.server.core.annotations.ApplyLdifFiles;
@@ -25,20 +26,21 @@ import org.apache.directory.shared.ldap.
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
-@RunWith( FrameworkRunner.class )
+
+@RunWith(FrameworkRunner.class)
 public class TestClassServer extends AbstractLdapTestUnit
 {
     @Test
-    @ApplyLdifFiles( "test-entry.ldif" )
+    @ApplyLdifFiles("test-entry.ldif")
     public void testWithApplyLdifFiles() throws Exception
     {
         assertTrue( getService().getAdminSession().exists( new Dn( "cn=testPerson1,ou=system" ) ) );
-        
+
         if ( isRunInSuite )
         {
             assertTrue( getService().getAdminSession().exists( new Dn( "dc=example,dc=com" ) ) );
         }
-        
+
         assertTrue( getService().getAdminSession().exists( new Dn( "cn=testPerson2,ou=system" ) ) );
     }
 }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestMultiLevelDS.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestMultiLevelDS.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestMultiLevelDS.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestMultiLevelDS.java Tue Jan 24 16:27:18 2012
@@ -20,6 +20,7 @@
 
 package org.apache.directory.server.core.integ;
 
+
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
@@ -28,35 +29,36 @@ import org.apache.directory.server.core.
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
+
 /**
  * TODO TestMultiLevelDS.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-@RunWith( FrameworkRunner.class )
-@CreateDS( name = "TestMultiLevelDS-class" )
+@RunWith(FrameworkRunner.class)
+@CreateDS(name = "TestMultiLevelDS-class")
 public class TestMultiLevelDS extends AbstractLdapTestUnit
 {
-    
+
     @Test
     public void testMethodWithClassLevelDs()
     {
         // to make this test pass standalone
-        if( isRunInSuite )
+        if ( isRunInSuite )
         {
             assertTrue( getLdapServer().getDirectoryService() == getService() );
         }
         assertFalse( getService().isAccessControlEnabled() );
         assertEquals( "TestMultiLevelDS-class", getService().getInstanceId() );
     }
-    
-    
+
+
     @Test
-    @CreateDS( enableAccessControl=true, name = "testMethodWithClassLevelDs-method" )
+    @CreateDS(enableAccessControl = true, name = "testMethodWithClassLevelDs-method")
     public void testMethodWithMethodLevelDs()
     {
         // to make this test pass standalone
-        if( isRunInSuite )
+        if ( isRunInSuite )
         {
             assertTrue( getLdapServer().getDirectoryService() == getService() );
         }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuite.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuite.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuite.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuite.java Tue Jan 24 16:27:18 2012
@@ -18,21 +18,24 @@
  */
 package org.apache.directory.server.core.integ;
 
+
 import org.apache.directory.server.core.annotations.ApplyLdifs;
 import org.apache.directory.server.core.annotations.CreateDS;
 import org.junit.runner.RunWith;
 import org.junit.runners.Suite;
 
-@RunWith( FrameworkSuite.class )
-@Suite.SuiteClasses( { TestClassA.class, TestClassB.class, TestClassC.class } )
-@CreateDS( name = "SuiteDS" )
+
+@RunWith(FrameworkSuite.class)
+@Suite.SuiteClasses(
+    { TestClassA.class, TestClassB.class, TestClassC.class })
+@CreateDS(name = "SuiteDS")
 @ApplyLdifs(
     {
-        "dn: cn=testSuite,ou=system", 
-        "objectClass: person", 
-        "cn: testSuite", 
-        "sn: sn_testSuite" 
-    })
+        "dn: cn=testSuite,ou=system",
+        "objectClass: person",
+        "cn: testSuite",
+        "sn: sn_testSuite"
+})
 public class TestSuite
 {
 }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteServer.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteServer.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteServer.java Tue Jan 24 16:27:18 2012
@@ -18,6 +18,7 @@
  */
 package org.apache.directory.server.core.integ;
 
+
 import org.apache.directory.server.annotations.CreateLdapServer;
 import org.apache.directory.server.annotations.CreateTransport;
 import org.apache.directory.server.core.annotations.ApplyLdifs;
@@ -28,41 +29,43 @@ import org.apache.directory.server.core.
 import org.junit.runner.RunWith;
 import org.junit.runners.Suite;
 
-@RunWith( FrameworkSuite.class )
-@Suite.SuiteClasses( { TestClassServer.class, TestMultiLevelDS.class } )
-@CreateDS( 
+
+@RunWith(FrameworkSuite.class)
+@Suite.SuiteClasses(
+    { TestClassServer.class, TestMultiLevelDS.class })
+@CreateDS(
     name = "SuiteDS",
     partitions =
-    {
-        @CreatePartition(
-            name = "example",
-            suffix = "dc=example,dc=com",
-            contextEntry = @ContextEntry( 
-                entryLdif =
+        {
+            @CreatePartition(
+                name = "example",
+                suffix = "dc=example,dc=com",
+                contextEntry = @ContextEntry(
+                    entryLdif =
                     "dn: dc=example,dc=com\n" +
-                    "dc: example\n" +
-                    "objectClass: top\n" +
-                    "objectClass: domain\n\n" ),
-            indexes = 
-            {
-                @CreateIndex( attribute = "objectClass" ),
-                @CreateIndex( attribute = "dc" ),
-                @CreateIndex( attribute = "ou" )
-            } )
-    } )
-@CreateLdapServer ( 
-    transports = 
-    {
-        @CreateTransport( protocol = "LDAP" ), 
-        @CreateTransport( protocol = "LDAPS" ) 
+                        "dc: example\n" +
+                        "objectClass: top\n" +
+                        "objectClass: domain\n\n"),
+                indexes =
+                    {
+                        @CreateIndex(attribute = "objectClass"),
+                        @CreateIndex(attribute = "dc"),
+                        @CreateIndex(attribute = "ou")
+                })
+    })
+@CreateLdapServer(
+    transports =
+        {
+            @CreateTransport(protocol = "LDAP"),
+            @CreateTransport(protocol = "LDAPS")
     })
 @ApplyLdifs(
     {
         "dn: cn=testSuite,ou=system",
         "objectClass: person",
         "cn: testSuite",
-        "sn: sn_testSuite" 
-    } )
+        "sn: sn_testSuite"
+})
 public class TestSuiteServer
 {
 }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteWithoutFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteWithoutFactory.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteWithoutFactory.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestSuiteWithoutFactory.java Tue Jan 24 16:27:18 2012
@@ -18,19 +18,22 @@
  */
 package org.apache.directory.server.core.integ;
 
+
 import org.apache.directory.server.core.annotations.ApplyLdifs;
 import org.junit.runner.RunWith;
 import org.junit.runners.Suite;
 
-@RunWith( FrameworkSuite.class )
-@Suite.SuiteClasses({ TestClassA.class, TestClassB.class, TestClassC.class })
+
+@RunWith(FrameworkSuite.class)
+@Suite.SuiteClasses(
+    { TestClassA.class, TestClassB.class, TestClassC.class })
 @ApplyLdifs(
     {
-        "dn: cn=testSuite,ou=system", 
-        "objectClass: person", 
-        "cn: testSuite", 
-        "sn: sn_testSuite" 
-    })
+        "dn: cn=testSuite,ou=system",
+        "objectClass: person",
+        "cn: testSuite",
+        "sn: sn_testSuite"
+})
 public class TestSuiteWithoutFactory
 {
 }

Modified: directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestWithClassLevelLdapServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestWithClassLevelLdapServer.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestWithClassLevelLdapServer.java (original)
+++ directory/apacheds/trunk/test-framework/src/test/java/org/apache/directory/server/core/integ/TestWithClassLevelLdapServer.java Tue Jan 24 16:27:18 2012
@@ -18,6 +18,7 @@
  */
 package org.apache.directory.server.core.integ;
 
+
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
 import static org.junit.Assert.assertTrue;
@@ -29,33 +30,35 @@ import org.apache.directory.shared.ldap.
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
-@RunWith( FrameworkRunner.class )
-@CreateLdapServer ( 
-    transports = 
-    {
-        @CreateTransport( protocol = "LDAP" )
+
+@RunWith(FrameworkRunner.class)
+@CreateLdapServer(
+    transports =
+        {
+            @CreateTransport(protocol = "LDAP")
     })
 public class TestWithClassLevelLdapServer extends AbstractLdapTestUnit
 {
     @Test
-    @ApplyLdifFiles( "test-entry.ldif" )
+    @ApplyLdifFiles("test-entry.ldif")
     public void testWithApplyLdifFiles() throws Exception
     {
         assertTrue( getService().getAdminSession().exists( new Dn( "cn=testPerson1,ou=system" ) ) );
-        
+
         if ( isRunInSuite )
         {
             assertTrue( getService().getAdminSession().exists( new Dn( "dc=example,dc=com" ) ) );
             // the SuiteDS is the name given to the DS instance in the enclosing TestSuite
             assertEquals( "SuiteDS", getLdapServer().getDirectoryService().getInstanceId() );
         }
-        else // should run with a default DS created in FrameworkRunner
+        else
+        // should run with a default DS created in FrameworkRunner
         {
             assertTrue( getLdapServer().getDirectoryService().getInstanceId().startsWith( "default" ) ); // after 'default' a UUID follows
         }
-        
+
         assertTrue( getService().getAdminSession().exists( new Dn( "cn=testPerson2,ou=system" ) ) );
-        
+
         assertNotNull( getLdapServer() );
     }
 }

Modified: directory/apacheds/trunk/wrapper/src/main/java/org/apache/directory/server/wrapper/ApacheDsTanukiWrapper.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/wrapper/src/main/java/org/apache/directory/server/wrapper/ApacheDsTanukiWrapper.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/wrapper/src/main/java/org/apache/directory/server/wrapper/ApacheDsTanukiWrapper.java (original)
+++ directory/apacheds/trunk/wrapper/src/main/java/org/apache/directory/server/wrapper/ApacheDsTanukiWrapper.java Tue Jan 24 16:27:18 2012
@@ -119,8 +119,8 @@ public class ApacheDsTanukiWrapper imple
             // We are not being controlled by the Wrapper, so
             // handle the event ourselves.
             if ( ( event == WrapperManager.WRAPPER_CTRL_C_EVENT ) ||
-                 ( event == WrapperManager.WRAPPER_CTRL_CLOSE_EVENT ) ||
-                 ( event == WrapperManager.WRAPPER_CTRL_SHUTDOWN_EVENT ) )
+                ( event == WrapperManager.WRAPPER_CTRL_CLOSE_EVENT ) ||
+                ( event == WrapperManager.WRAPPER_CTRL_SHUTDOWN_EVENT ) )
             {
                 WrapperManager.stop( 0 );
             }

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/avl/AvlPartition.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/avl/AvlPartition.java?rev=1235334&r1=1235333&r2=1235334&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/avl/AvlPartition.java (original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/avl/AvlPartition.java Tue Jan 24 16:27:18 2012
@@ -50,7 +50,7 @@ public class AvlPartition extends Abstra
     /** static logger */
     private static final Logger LOG = LoggerFactory.getLogger( AvlPartition.class );
 
-    
+
     /**
      * Creates a store based on AVL Trees.
      */
@@ -69,7 +69,7 @@ public class AvlPartition extends Abstra
         {
             EvaluatorBuilder<Long> evaluatorBuilder = new EvaluatorBuilder<Long>( this, schemaManager );
             CursorBuilder<Long> cursorBuilder = new CursorBuilder<Long>( this, evaluatorBuilder );
-    
+
             // setup optimizer and registries for parent
             if ( !optimizerEnabled )
             {
@@ -79,17 +79,17 @@ public class AvlPartition extends Abstra
             {
                 optimizer = new DefaultOptimizer<Entry, Long>( this );
             }
-    
+
             searchEngine = new DefaultSearchEngine<Long>( this, cursorBuilder, evaluatorBuilder, optimizer );
-    
+
             if ( isInitialized() )
             {
                 return;
             }
-    
+
             // Create the master table (the table containing all the entries)
             master = new AvlMasterTable<Entry>( id, new LongComparator(), null, false );
-    
+
             super.doInit();
         }
     }
@@ -153,7 +153,7 @@ public class AvlPartition extends Abstra
         }
         else if ( index instanceof AvlIndex<?, ?> )
         {
-            avlIndex = (AvlIndex<?, Entry> ) index;
+            avlIndex = ( AvlIndex<?, Entry> ) index;
         }
         else
         {
@@ -161,13 +161,13 @@ public class AvlPartition extends Abstra
                 + "Will create new AvlIndex using copied configuration parameters.", index );
             avlIndex = new AvlIndex( index.getAttributeId() );
         }
-     
+
         avlIndex.init( schemaManager, schemaManager.lookupAttributeTypeRegistry( index.getAttributeId() ) );
-      
+
         return avlIndex;
     }
 
-    
+
     /**
      * {@inheritDoc}
      */