directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r584849 - in /directory/apacheds/branches/bigbang: protocol-changepw/src/main/java/org/apache/directory/server/changepw/ protocol-changepw/src/test/java/org/apache/directory/server/changepw/protocol/ protocol-dns/src/main/java/org/apache/di...
Date Mon, 15 Oct 2007 18:57:53 GMT
Author: djencks
Date: Mon Oct 15 11:57:51 2007
New Revision: 584849

URL: http://svn.apache.org/viewvc?rev=584849&view=rev
Log:
Remove final vars, use setter injection per Alex's request.  I think this increases the likelyhood
of using unitialized components

Modified:
    directory/apacheds/branches/bigbang/protocol-changepw/src/main/java/org/apache/directory/server/changepw/ChangePasswordServer.java
    directory/apacheds/branches/bigbang/protocol-changepw/src/test/java/org/apache/directory/server/changepw/protocol/ChangepwProtocolHandlerTest.java
    directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/DnsServer.java
    directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/Main.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcServer.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/kdc/SaslGssapiBindITest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationEncryptionTypeTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationPolicyTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationServiceTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/EncTktInSkeyTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/PreAuthenticationTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingEncryptionTypeTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingPolicyTest.java
    directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingServiceTest.java
    directory/apacheds/branches/bigbang/protocol-ntp/src/main/java/org/apache/directory/server/ntp/NtpServer.java
    directory/apacheds/branches/bigbang/protocol-ntp/src/test/java/org/apache/directory/server/ntp/NtpITest.java

Modified: directory/apacheds/branches/bigbang/protocol-changepw/src/main/java/org/apache/directory/server/changepw/ChangePasswordServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-changepw/src/main/java/org/apache/directory/server/changepw/ChangePasswordServer.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-changepw/src/main/java/org/apache/directory/server/changepw/ChangePasswordServer.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-changepw/src/main/java/org/apache/directory/server/changepw/ChangePasswordServer.java
Mon Oct 15 11:57:51 2007
@@ -112,21 +112,21 @@
     /** The policy for token size. */
     private int policyTokenSize;
 
-    private final DirectoryService directoryService;
+    /** DirectoryService backend for this server */
+    private DirectoryService directoryService;
 
-    private final DatagramAcceptor datagramAcceptor;
-    private final SocketAcceptor socketAcceptor;
+    /** DatagramAcceptor input for this server */
+    private DatagramAcceptor datagramAcceptor;
+
+    /** SocketAcceptor input for this server */
+    private SocketAcceptor socketAcceptor;
 
 
     /**
      * Creates a new instance of ChangePasswordConfiguration.
      */
-    public ChangePasswordServer( DatagramAcceptor datagramAcceptor, SocketAcceptor socketAcceptor,
DirectoryService directoryService )
+    public ChangePasswordServer()
     {
-        this.datagramAcceptor = datagramAcceptor;
-        this.socketAcceptor = socketAcceptor;
-        this.directoryService = directoryService;
-
         super.setServiceName( SERVICE_NAME_DEFAULT );
         super.setIpPort( IP_PORT_DEFAULT );
         super.setServicePid( SERVICE_PID_DEFAULT );
@@ -135,6 +135,59 @@
         prepareEncryptionTypes();
     }
 
+    /**
+     * Returns the backend for this server
+     * @return DirectoryService backend for this server
+     */
+    public DirectoryService getDirectoryService()
+    {
+        return directoryService;
+    }
+
+    /**
+     * Set the backend for this server
+     * @param directoryService the DirectoryService backend for this server
+     */
+    public void setDirectoryService( DirectoryService directoryService )
+    {
+        this.directoryService = directoryService;
+    }
+
+    /**
+     * Returns the DatagramAcceptor input for this server
+     * @return DatagramAcceptor input for this server
+     */
+    public DatagramAcceptor getDatagramAcceptor()
+    {
+        return datagramAcceptor;
+    }
+
+    /**
+     * Set the DatagramAcceptor for this server
+     * @param datagramAcceptor the DatagramAcceptor input for this server
+     */
+    public void setDatagramAcceptor( DatagramAcceptor datagramAcceptor )
+    {
+        this.datagramAcceptor = datagramAcceptor;
+    }
+
+    /**
+     * Returns the SocketAcceptor for this server
+     * @return SocketAcceptor input for this server
+     */
+    public SocketAcceptor getSocketAcceptor()
+    {
+        return socketAcceptor;
+    }
+
+    /**
+     * Set the SocketAcceptor for this server
+     * @param socketAcceptor the SocketAcceptor input for this server
+     */
+    public void setSocketAcceptor( SocketAcceptor socketAcceptor )
+    {
+        this.socketAcceptor = socketAcceptor;
+    }
 
     /**
      * Returns the primary realm.

Modified: directory/apacheds/branches/bigbang/protocol-changepw/src/test/java/org/apache/directory/server/changepw/protocol/ChangepwProtocolHandlerTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-changepw/src/test/java/org/apache/directory/server/changepw/protocol/ChangepwProtocolHandlerTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-changepw/src/test/java/org/apache/directory/server/changepw/protocol/ChangepwProtocolHandlerTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-changepw/src/test/java/org/apache/directory/server/changepw/protocol/ChangepwProtocolHandlerTest.java
Mon Oct 15 11:57:51 2007
@@ -97,7 +97,7 @@
      */
     public ChangepwProtocolHandlerTest()
     {
-        config = new ChangePasswordServer( null, null, null );
+        config = new ChangePasswordServer();
         store = new MapPrincipalStoreImpl();
         handler = new ChangePasswordProtocolHandler( config, store );
         session = new DummySession();

Modified: directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/DnsServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/DnsServer.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/DnsServer.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/DnsServer.java
Mon Oct 15 11:57:51 2007
@@ -55,22 +55,78 @@
     /** The default service name. */
     private static final String SERVICE_NAME_DEFAULT = "ApacheDS DNS Service";
 
-    private final DirectoryService directoryService;
-    private final DatagramAcceptor datagramAcceptor;
-    private final SocketAcceptor socketAcceptor;
+    /** DirectoryService backend for this server */
+    private DirectoryService directoryService;
+
+    /** DatagramAcceptor input for this server */
+    private DatagramAcceptor datagramAcceptor;
+
+    /** SocketAcceptor input for this server */
+    private SocketAcceptor socketAcceptor;
 
 
     /**
      * Creates a new instance of DnsConfiguration.
      */
-    public DnsServer(  DatagramAcceptor datagramAcceptor, SocketAcceptor socketAcceptor,
DirectoryService directoryService)
+    public DnsServer()
     {
-        this.datagramAcceptor = datagramAcceptor;
-        this.socketAcceptor = socketAcceptor;
-        this.directoryService = directoryService;
         super.setIpPort( IP_PORT_DEFAULT );
         super.setServicePid( SERVICE_PID_DEFAULT );
         super.setServiceName( SERVICE_NAME_DEFAULT );
+    }
+
+    /**
+     * Returns the backend for this server
+     * @return DirectoryService backend for this server
+     */
+    public DirectoryService getDirectoryService()
+    {
+        return directoryService;
+    }
+
+    /**
+     * Set the backend for this server
+     * @param directoryService the DirectoryService backend for this server
+     */
+    public void setDirectoryService( DirectoryService directoryService )
+    {
+        this.directoryService = directoryService;
+    }
+
+    /**
+     * Returns the DatagramAcceptor input for this server
+     * @return DatagramAcceptor input for this server
+     */
+    public DatagramAcceptor getDatagramAcceptor()
+    {
+        return datagramAcceptor;
+    }
+
+    /**
+     * Set the DatagramAcceptor for this server
+     * @param datagramAcceptor the DatagramAcceptor input for this server
+     */
+    public void setDatagramAcceptor( DatagramAcceptor datagramAcceptor )
+    {
+        this.datagramAcceptor = datagramAcceptor;
+    }
+
+    /**
+     * Returns the SocketAcceptor for this server
+     * @return SocketAcceptor input for this server
+     */
+    public SocketAcceptor getSocketAcceptor()
+    {
+        return socketAcceptor;
+    }
+
+    /**
+     * Set the SocketAcceptor for this server
+     * @param socketAcceptor the SocketAcceptor input for this server
+     */
+    public void setSocketAcceptor( SocketAcceptor socketAcceptor )
+    {
+        this.socketAcceptor = socketAcceptor;
     }
 
     /**

Modified: directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/Main.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/Main.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/Main.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-dns/src/main/java/org/apache/directory/server/dns/Main.java
Mon Oct 15 11:57:51 2007
@@ -61,7 +61,10 @@
         DatagramAcceptor datagramAcceptor = new DatagramAcceptor( null );
         SocketAcceptor socketAcceptor = new SocketAcceptor( null );
         DirectoryService directoryService = new DefaultDirectoryService();
-        dnsConfiguration = new DnsServer( datagramAcceptor, socketAcceptor, directoryService
);
+        dnsConfiguration = new DnsServer();
+        dnsConfiguration.setDatagramAcceptor( datagramAcceptor );
+        dnsConfiguration.setSocketAcceptor( socketAcceptor );
+        dnsConfiguration.setDirectoryService( directoryService );
         dnsConfiguration.setEnabled( true );
         dnsConfiguration.setIpPort( 10053 );
         dnsConfiguration.start();

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcServer.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcServer.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcServer.java
Mon Oct 15 11:57:51 2007
@@ -143,24 +143,80 @@
     private boolean isBodyChecksumVerified = DEFAULT_VERIFY_BODY_CHECKSUM;
 
 
-    private final DirectoryService directoryService;
-    private final DatagramAcceptor datagramAcceptor;
-    private final SocketAcceptor socketAcceptor;
+    /** DirectoryService backend for this server */
+    private DirectoryService directoryService;
+
+    /** DatagramAcceptor input for this server */
+    private DatagramAcceptor datagramAcceptor;
+
+    /** SocketAcceptor input for this server */
+    private SocketAcceptor socketAcceptor;
 
     /**
      * Creates a new instance of KdcConfiguration.
      */
-    public KdcServer(  DatagramAcceptor datagramAcceptor, SocketAcceptor socketAcceptor,
DirectoryService directoryService)
+    public KdcServer()
     {
-        this.datagramAcceptor = datagramAcceptor;
-        this.socketAcceptor = socketAcceptor;
-        this.directoryService = directoryService;
         super.setServiceName( DEFAULT_NAME );
         super.setIpPort( DEFAULT_IP_PORT );
         super.setServicePid( DEFAULT_PID );
         super.setSearchBaseDn( DEFAULT_SEARCH_BASEDN );
 
         prepareEncryptionTypes();
+    }
+
+    /**
+     * Returns the backend for this server
+     * @return DirectoryService backend for this server
+     */
+    public DirectoryService getDirectoryService()
+    {
+        return directoryService;
+    }
+
+    /**
+     * Set the backend for this server
+     * @param directoryService the DirectoryService backend for this server
+     */
+    public void setDirectoryService( DirectoryService directoryService )
+    {
+        this.directoryService = directoryService;
+    }
+
+    /**
+     * Returns the DatagramAcceptor input for this server
+     * @return DatagramAcceptor input for this server
+     */
+    public DatagramAcceptor getDatagramAcceptor()
+    {
+        return datagramAcceptor;
+    }
+
+    /**
+     * Set the DatagramAcceptor for this server
+     * @param datagramAcceptor the DatagramAcceptor input for this server
+     */
+    public void setDatagramAcceptor( DatagramAcceptor datagramAcceptor )
+    {
+        this.datagramAcceptor = datagramAcceptor;
+    }
+
+    /**
+     * Returns the SocketAcceptor for this server
+     * @return SocketAcceptor input for this server
+     */
+    public SocketAcceptor getSocketAcceptor()
+    {
+        return socketAcceptor;
+    }
+
+    /**
+     * Set the SocketAcceptor for this server
+     * @param socketAcceptor the SocketAcceptor input for this server
+     */
+    public void setSocketAcceptor( SocketAcceptor socketAcceptor )
+    {
+        this.socketAcceptor = socketAcceptor;
     }
 
 

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/kdc/SaslGssapiBindITest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/kdc/SaslGssapiBindITest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/kdc/SaslGssapiBindITest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/kdc/SaslGssapiBindITest.java
Mon Oct 15 11:57:51 2007
@@ -21,7 +21,6 @@
 
 
 import org.apache.directory.server.core.DirectoryService;
-import org.apache.directory.server.core.DefaultDirectoryService;
 import org.apache.directory.server.core.interceptor.Interceptor;
 import org.apache.directory.server.core.kerberos.KeyDerivationInterceptor;
 import org.apache.directory.server.core.partition.Partition;
@@ -29,13 +28,10 @@
 import org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmIndex;
 import org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmPartition;
 import org.apache.directory.server.kerberos.shared.store.KerberosAttribute;
-import org.apache.directory.server.ldap.LdapServer;
-import org.apache.directory.server.protocol.shared.SocketAcceptor;
 import org.apache.directory.server.unit.AbstractServerTest;
 import org.apache.directory.shared.ldap.message.AttributeImpl;
 import org.apache.directory.shared.ldap.message.AttributesImpl;
 import org.apache.directory.shared.ldap.message.ModificationItemImpl;
-import org.apache.mina.util.AvailablePortFinder;
 
 import javax.naming.Context;
 import javax.naming.directory.Attribute;
@@ -86,7 +82,9 @@
         ldapServer.setSaslHost( "localhost" );
         ldapServer.setSaslPrincipal( "ldap/localhost@EXAMPLE.COM" );
 
-        KdcServer kdcConfig = new KdcServer( null, socketAcceptor, directoryService );
+        KdcServer kdcConfig = new KdcServer();
+        kdcConfig.setSocketAcceptor( socketAcceptor );
+        kdcConfig.setDirectoryService( directoryService );
         kdcConfig.setEnabled( true );
         kdcConfig.setSearchBaseDn( "ou=users,dc=example,dc=com" );
         kdcConfig.setSecurityAuthentication( "simple" );

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationEncryptionTypeTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationEncryptionTypeTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationEncryptionTypeTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationEncryptionTypeTest.java
Mon Oct 15 11:57:51 2007
@@ -68,7 +68,7 @@
      */
     public AuthenticationEncryptionTypeTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
         store = new MapPrincipalStoreImpl();
         handler = new KerberosProtocolHandler( config, store );
         session = new DummySession();

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationPolicyTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationPolicyTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationPolicyTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationPolicyTest.java
Mon Oct 15 11:57:51 2007
@@ -49,7 +49,7 @@
      */
     public AuthenticationPolicyTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
         store = new MapPrincipalStoreImpl();
         handler = new KerberosProtocolHandler( config, store );
         session = new DummySession();

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationServiceTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationServiceTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationServiceTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/AuthenticationServiceTest.java
Mon Oct 15 11:57:51 2007
@@ -56,7 +56,7 @@
      */
     public AuthenticationServiceTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
         store = new MapPrincipalStoreImpl();
         handler = new KerberosProtocolHandler( config, store );
         session = new DummySession();

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/EncTktInSkeyTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/EncTktInSkeyTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/EncTktInSkeyTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/EncTktInSkeyTest.java
Mon Oct 15 11:57:51 2007
@@ -56,7 +56,7 @@
      */
     public EncTktInSkeyTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
 
         /*
          * Body checksum verification must be disabled because we are bypassing

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/PreAuthenticationTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/PreAuthenticationTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/PreAuthenticationTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/PreAuthenticationTest.java
Mon Oct 15 11:57:51 2007
@@ -61,7 +61,7 @@
      */
     public PreAuthenticationTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
         store = new MapPrincipalStoreImpl();
         handler = new KerberosProtocolHandler( config, store );
         session = new DummySession();

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingEncryptionTypeTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingEncryptionTypeTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingEncryptionTypeTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingEncryptionTypeTest.java
Mon Oct 15 11:57:51 2007
@@ -62,7 +62,7 @@
      */
     public TicketGrantingEncryptionTypeTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
 
         /*
          * Body checksum verification must be disabled because we are bypassing

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingPolicyTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingPolicyTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingPolicyTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingPolicyTest.java
Mon Oct 15 11:57:51 2007
@@ -60,7 +60,7 @@
      */
     public TicketGrantingPolicyTest()
     {
-        config = new KdcServer( null, null, null );
+        config = new KdcServer();
 
         /*
          * Body checksum verification must be disabled because we are bypassing

Modified: directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingServiceTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingServiceTest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingServiceTest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-kerberos/src/test/java/org/apache/directory/server/kerberos/protocol/TicketGrantingServiceTest.java
Mon Oct 15 11:57:51 2007
@@ -66,7 +66,7 @@
      */
     public TicketGrantingServiceTest()
     {
-        config = new KdcServer(null, null, null);
+        config = new KdcServer();
 
         /*
          * Body checksum verification must be disabled because we are bypassing

Modified: directory/apacheds/branches/bigbang/protocol-ntp/src/main/java/org/apache/directory/server/ntp/NtpServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ntp/src/main/java/org/apache/directory/server/ntp/NtpServer.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ntp/src/main/java/org/apache/directory/server/ntp/NtpServer.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-ntp/src/main/java/org/apache/directory/server/ntp/NtpServer.java
Mon Oct 15 11:57:51 2007
@@ -58,21 +58,58 @@
      */
     private static final String SERVICE_NAME_DEFAULT = "ApacheDS NTP Service";
 
-    private final DatagramAcceptor datagramAcceptor;
-    private final SocketAcceptor socketAcceptor;
+    /** DatagramAcceptor input for this server */
+    private DatagramAcceptor datagramAcceptor;
+
+    /** SocketAcceptor input for this server */
+    private SocketAcceptor socketAcceptor;
+
 
     /**
      * Creates a new instance of NtpConfiguration.
      */
-    public NtpServer( DatagramAcceptor datagramAcceptor, SocketAcceptor socketAcceptor )
+    public NtpServer()
     {
-        this.datagramAcceptor = datagramAcceptor;
-        this.socketAcceptor = socketAcceptor;
         super.setIpPort( IP_PORT_DEFAULT );
         super.setServicePid( SERVICE_PID_DEFAULT );
         super.setServiceName( SERVICE_NAME_DEFAULT );
     }
 
+    /**
+     * Returns the DatagramAcceptor input for this server
+     * @return DatagramAcceptor input for this server
+     */
+    public DatagramAcceptor getDatagramAcceptor()
+    {
+        return datagramAcceptor;
+    }
+
+    /**
+     * Set the DatagramAcceptor for this server
+     * @param datagramAcceptor the DatagramAcceptor input for this server
+     */
+    public void setDatagramAcceptor( DatagramAcceptor datagramAcceptor )
+    {
+        this.datagramAcceptor = datagramAcceptor;
+    }
+
+    /**
+     * Returns the SocketAcceptor for this server
+     * @return SocketAcceptor input for this server
+     */
+    public SocketAcceptor getSocketAcceptor()
+    {
+        return socketAcceptor;
+    }
+
+    /**
+     * Set the SocketAcceptor for this server
+     * @param socketAcceptor the SocketAcceptor input for this server
+     */
+    public void setSocketAcceptor( SocketAcceptor socketAcceptor )
+    {
+        this.socketAcceptor = socketAcceptor;
+    }
     /**
      * @org.apache.xbean.InitMethod
      */

Modified: directory/apacheds/branches/bigbang/protocol-ntp/src/test/java/org/apache/directory/server/ntp/NtpITest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ntp/src/test/java/org/apache/directory/server/ntp/NtpITest.java?rev=584849&r1=584848&r2=584849&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ntp/src/test/java/org/apache/directory/server/ntp/NtpITest.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-ntp/src/test/java/org/apache/directory/server/ntp/NtpITest.java
Mon Oct 15 11:57:51 2007
@@ -49,7 +49,8 @@
     public void setUp() throws Exception
     {
         DatagramAcceptor datagramAcceptor = new DatagramAcceptor( null );
-        ntpConfig = new NtpServer( datagramAcceptor, null );
+        ntpConfig = new NtpServer();
+        ntpConfig.setDatagramAcceptor( datagramAcceptor );
         ntpConfig.setEnabled( true );
         port = AvailablePortFinder.getNextAvailable( 10123 );
         ntpConfig.setIpPort( port );



Mime
View raw message