directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r373703 - in /directory/trunks: apacheds/core/src/main/java/org/apache/ldap/server/partition/ apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/ apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/suppo...
Date Tue, 31 Jan 2006 04:54:22 GMT
Author: akarasulu
Date: Mon Jan 30 20:54:10 2006
New Revision: 373703

URL: http://svn.apache.org/viewcvs?rev=373703&view=rev
Log:
Enhanced extendedOperation support and plugability:

 o added a set of extra methods to ExtendedOperationHandler which setup the
   handler with some objects that may be needed for the handler to manage
   various kinds of extended operations
 o this allowed us to remove dependencies on specific handlers in the server
   JNDI context factory implementation 
 o corrected consistency issue in constant names for extended message oid
 o added methods to the nexus and proxy to register a set of OIDs for publishing
   them in the rootDSE in the supportedExtension attribute


Modified:
    directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DefaultDirectoryPartitionNexus.java
    directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexus.java
    directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexusProxy.java
    directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/ExtendedOperationHandler.java
    directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/ExtendedHandler.java
    directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/GracefulShutdownHandler.java
    directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/LaunchDiagnosticUiHandler.java
    directory/trunks/apacheds/standalone/simple/jndi/src/main/java/org/apache/ldap/server/jndi/ServerContextFactory.java
    directory/trunks/apacheds/tools/src/test/java/org/apache/ldap/server/dumptool/NotificationsExample.java
    directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/GracefulDisconnect.java
    directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/NoticeOfDisconnect.java

Modified: directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DefaultDirectoryPartitionNexus.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DefaultDirectoryPartitionNexus.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DefaultDirectoryPartitionNexus.java
(original)
+++ directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DefaultDirectoryPartitionNexus.java
Mon Jan 30 20:54:10 2006
@@ -56,8 +56,7 @@
 import org.apache.ldap.common.message.ManageDsaITControl;
 import org.apache.ldap.common.message.PersistentSearchControl;
 import org.apache.ldap.common.message.SubentriesControl;
-import org.apache.ldap.common.message.extended.LaunchDiagnosticUiRequest;
-import org.apache.ldap.common.message.extended.LaunchDiagnosticUiResponse;
+import org.apache.ldap.common.message.extended.NoticeOfDisconnect;
 import org.apache.ldap.common.name.LdapName;
 import org.apache.ldap.common.util.DateUtils;
 import org.apache.ldap.common.util.NamespaceTools;
@@ -68,6 +67,7 @@
 import org.apache.ldap.server.configuration.MutableDirectoryPartitionConfiguration;
 import org.apache.ldap.server.partition.impl.btree.jdbm.JdbmDirectoryPartition;
 import org.apache.ldap.server.schema.AttributeTypeRegistry;
+
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -136,8 +136,7 @@
 
         attr = new LockableAttributeImpl( "supportedExtension" );
         rootDSE.put( attr );
-        attr.add( LaunchDiagnosticUiRequest.EXTENSION_OID );
-        attr.add( LaunchDiagnosticUiResponse.EXTENSION_OID );
+        attr.add( NoticeOfDisconnect.EXTENSION_OID );
 
         attr = new LockableAttributeImpl( "supportedControl" );
         rootDSE.put( attr );
@@ -789,5 +788,20 @@
     public DirectoryPartition getPartition( Name dn ) throws NamingException
     {
         return getBackend( dn );
+    }
+
+
+    public void registerSupportedExtensions( Set extensionOids )
+    {
+        Attribute supportedExtension = rootDSE.get( "supportedExtension" );
+        if ( supportedExtension == null )
+        {
+            supportedExtension = new LockableAttributeImpl( "supportedExtension" );
+            rootDSE.put( supportedExtension );
+        }
+        for ( Iterator oids = extensionOids.iterator(); oids.hasNext(); )
+        {
+            supportedExtension.add( ( String ) oids.next() );
+        }
     }
 }

Modified: directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexus.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexus.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexus.java
(original)
+++ directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexus.java
Mon Jan 30 20:54:10 2006
@@ -18,6 +18,7 @@
 
 
 import java.util.Iterator;
+import java.util.Set;
 
 import javax.naming.Name;
 import javax.naming.NamingException;
@@ -205,4 +206,12 @@
      * @throws NamingException if there are any problems
      */
     public abstract Iterator listSuffixes( boolean normalized ) throws NamingException;
+
+    /**
+     * Adds a set of supportedExtension (OID Strings) to the RootDSE.
+     * 
+     * @param extensionOids a set of OID strings to add to the supportedExtension 
+     * attribute in the RootDSE
+     */
+    public abstract void registerSupportedExtensions( Set extensionOids );
 }

Modified: directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexusProxy.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexusProxy.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexusProxy.java
(original)
+++ directory/trunks/apacheds/core/src/main/java/org/apache/ldap/server/partition/DirectoryPartitionNexusProxy.java
Mon Jan 30 20:54:10 2006
@@ -690,6 +690,12 @@
     }
 
 
+    public void registerSupportedExtensions( Set extensionOids )
+    {
+        configuration.getPartitionNexus().registerSupportedExtensions( extensionOids );
+    }
+
+    
     // -----------------------------------------------------------------------
     // EventContext and EventDirContext notification methods
     // -----------------------------------------------------------------------

Modified: directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/ExtendedOperationHandler.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/ExtendedOperationHandler.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/ExtendedOperationHandler.java
(original)
+++ directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/ExtendedOperationHandler.java
Mon Jan 30 20:54:10 2006
@@ -18,8 +18,14 @@
  */
 package org.apache.ldap.server.protocol;
 
+
+import java.util.Set;
+
 import org.apache.ldap.common.message.ExtendedRequest;
 import org.apache.mina.common.IoSession;
+import org.apache.mina.registry.Service;
+import org.apache.mina.registry.ServiceRegistry;
+
 
 /**
  * An extension (hook) point that enables an implementor to provide his or her
@@ -32,11 +38,20 @@
 public interface ExtendedOperationHandler
 {
     /**
-     * Returns the OID of the extended operation this handler can handle.
+     * Returns the EXTENSION_OID of the extended request this handler can handle.
      */
     String getOid();
     
     /**
+     * The OIDs of the extensions supported by this handler.  This includes the 
+     * request as well as any responses associated with the request.  These OIDs 
+     * will be registered with the server to publish them as supportedExtensions.
+     * 
+     * @return the OIDs supported by this handler.
+     */
+    Set getExtensionOids();
+    
+    /**
      * Handles the specified extended operation.
      * 
      * @param session the MINA session object related with current connection
@@ -45,4 +60,25 @@
      * @throws Exception if failed to handle the operation
      */
     void handleExtendedOperation( IoSession session, SessionRegistry registry, ExtendedRequest
req ) throws Exception;
+    
+    /**
+     * Sets the LDAP provider for this extendedOperation handler.
+     * 
+     * @param provider the ldap protocol provider 
+     */
+    void setLdapProvider( LdapProtocolProvider provider );
+    
+    /**
+     * Sets the LDAP service for the this extenedOperation handler.
+     * 
+     * @param service the MINA service for LDAP or LDAPS
+     */
+    void setLdapService( Service service );
+    
+    /**
+     * Sets the MINA service registry for this extendedOperation handler.
+     * 
+     * @param registry the MINA service registry
+     */
+    void setServiceRegistry( ServiceRegistry registry );
 }

Modified: directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/ExtendedHandler.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/ExtendedHandler.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/ExtendedHandler.java
(original)
+++ directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/ExtendedHandler.java
Mon Jan 30 20:54:10 2006
@@ -82,7 +82,7 @@
         {
             // As long as no extended operations are implemented, send appropriate
             // error back to the client.
-            String msg = "Unrecognized extended operation OID: " + req.getOid();
+            String msg = "Unrecognized extended operation EXTENSION_OID: " + req.getOid();
             LdapResult result = req.getResultResponse().getLdapResult();        
             result.setResultCode( ResultCodeEnum.PROTOCOLERROR );
             result.setErrorMessage( msg );
@@ -99,7 +99,7 @@
                 LdapResult result = req.getResultResponse().getLdapResult();
                 result.setResultCode( ResultCodeEnum.UNAVAILABLE );
                 result.setErrorMessage(
-                        "Extended operation handler for the specified OID (" +
+                        "Extended operation handler for the specified EXTENSION_OID (" +
                         req.getOid() + ") has failed to process your request:\n" +
                         ExceptionUtils.getStackTrace( e ) );
                 ( ( ExtendedResponse ) req.getResultResponse() ).setResponse( new byte[ 0
] );

Modified: directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/GracefulShutdownHandler.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/GracefulShutdownHandler.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/GracefulShutdownHandler.java
(original)
+++ directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/GracefulShutdownHandler.java
Mon Jan 30 20:54:10 2006
@@ -18,8 +18,11 @@
 
 
 import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Set;
 
 import javax.naming.NamingException;
 import javax.naming.ldap.LdapContext;
@@ -36,6 +39,7 @@
 import org.apache.ldap.server.jndi.ServerLdapContext;
 import org.apache.ldap.server.partition.DirectoryPartitionNexus;
 import org.apache.ldap.server.protocol.ExtendedOperationHandler;
+import org.apache.ldap.server.protocol.LdapProtocolProvider;
 import org.apache.ldap.server.protocol.SessionRegistry;
 
 import org.apache.mina.common.IoAcceptor;
@@ -51,22 +55,20 @@
 public class GracefulShutdownHandler implements ExtendedOperationHandler
 {
     private static final Logger log = LoggerFactory.getLogger( GracefulShutdownHandler.class
);
+    public static final Set EXTENSION_OIDS;
+    
+    static
+    {
+        Set set = new HashSet( 3 );
+        set.add( GracefulShutdownRequest.EXTENSION_OID );
+        set.add( GracefulShutdownResponse.EXTENSION_OID );
+        set.add( GracefulDisconnect.EXTENSION_OID );
+        EXTENSION_OIDS = Collections.unmodifiableSet( set );
+    }
     
     private ServiceRegistry serviceRegistry;
     private Service ldapService;
     
-    
-    public void setLdapService( Service ldapService )
-    {
-        this.ldapService = ldapService;
-    }
-
-
-    public void setServiceRegistry( ServiceRegistry registry )
-    {
-        this.serviceRegistry = registry;
-    }
-
 
     public String getOid()
     {
@@ -338,5 +340,28 @@
                 }
             }
         }
+    }
+
+
+    public Set getExtensionOids()
+    {
+        return EXTENSION_OIDS;
+    }
+
+
+    public void setLdapProvider( LdapProtocolProvider provider )
+    {
+    }
+
+
+    public void setServiceRegistry( ServiceRegistry registry )
+    {
+        this.serviceRegistry = registry;
+    }
+
+
+    public void setLdapService( Service service )
+    {
+        this.ldapService = service;
     }
 }

Modified: directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/LaunchDiagnosticUiHandler.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/LaunchDiagnosticUiHandler.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/LaunchDiagnosticUiHandler.java
(original)
+++ directory/trunks/apacheds/protocols/ldap/src/main/java/org/apache/ldap/server/protocol/support/extended/LaunchDiagnosticUiHandler.java
Mon Jan 30 20:54:10 2006
@@ -20,7 +20,10 @@
 import java.awt.Dimension;
 import java.awt.Point;
 import java.awt.Toolkit;
+import java.util.Collections;
+import java.util.HashSet;
 import java.util.Iterator;
+import java.util.Set;
 
 import javax.naming.NamingException;
 import javax.naming.ldap.LdapContext;
@@ -48,6 +51,16 @@
 
 public class LaunchDiagnosticUiHandler implements ExtendedOperationHandler
 {
+    public static final Set EXTENSION_OIDS;
+    
+    static
+    {
+        Set set = new HashSet( 3 );
+        set.add( LaunchDiagnosticUiRequest.EXTENSION_OID );
+        set.add( LaunchDiagnosticUiResponse.EXTENSION_OID );
+        EXTENSION_OIDS = Collections.unmodifiableSet( set );
+    }
+    
     private Service ldapService;
     private ServiceRegistry minaRegistry;
     private LdapProtocolProvider ldapProvider;
@@ -135,32 +148,26 @@
     }
 
 
-    public void setLdapService( Service ldapService )
-    {
-        this.ldapService = ldapService;
-    }
-
-
-    public Service getLdapService()
+    public Set getExtensionOids()
     {
-        return ldapService;
+        return EXTENSION_OIDS;
     }
 
 
-    public void setServiceRegistry( ServiceRegistry minaRegistry )
+    public void setLdapProvider( LdapProtocolProvider provider )
     {
-        this.minaRegistry = minaRegistry;
+        this.ldapProvider = provider;
     }
 
 
-    public ServiceRegistry getMinaRegistry()
+    public void setLdapService( Service service )
     {
-        return minaRegistry;
+        this.ldapService = service;
     }
 
 
-    public void setLdapProvider( LdapProtocolProvider ldapProvider )
+    public void setServiceRegistry( ServiceRegistry registry )
     {
-        this.ldapProvider = ldapProvider;
+        this.minaRegistry = registry;
     }
 }

Modified: directory/trunks/apacheds/standalone/simple/jndi/src/main/java/org/apache/ldap/server/jndi/ServerContextFactory.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/standalone/simple/jndi/src/main/java/org/apache/ldap/server/jndi/ServerContextFactory.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/standalone/simple/jndi/src/main/java/org/apache/ldap/server/jndi/ServerContextFactory.java
(original)
+++ directory/trunks/apacheds/standalone/simple/jndi/src/main/java/org/apache/ldap/server/jndi/ServerContextFactory.java
Mon Jan 30 20:54:10 2006
@@ -45,10 +45,9 @@
 import org.apache.ldap.common.message.extended.NoticeOfDisconnect;
 import org.apache.ldap.server.DirectoryService;
 import org.apache.ldap.server.configuration.ServerStartupConfiguration;
+import org.apache.ldap.server.partition.DirectoryPartitionNexus;
 import org.apache.ldap.server.protocol.ExtendedOperationHandler;
 import org.apache.ldap.server.protocol.LdapProtocolProvider;
-import org.apache.ldap.server.protocol.support.extended.GracefulShutdownHandler;
-import org.apache.ldap.server.protocol.support.extended.LaunchDiagnosticUiHandler;
 import org.apache.mina.common.DefaultIoFilterChainBuilder;
 import org.apache.mina.common.IoAcceptor;
 import org.apache.mina.common.IoFilterChainBuilder;
@@ -84,8 +83,15 @@
     private static ChangePasswordServer changePasswordServer;
     private static NtpServer ntpServer;
     private static ServiceRegistry minaRegistry;
+    private DirectoryService directoryService;
 
 
+    public void beforeStartup( DirectoryService service )
+    {
+        this.directoryService = service;
+    }
+    
+    
     protected ServiceRegistry getMinaRegistry()
     {
         return minaRegistry;
@@ -407,20 +413,11 @@
             ExtendedOperationHandler h = ( ExtendedOperationHandler ) i.next();
             protocolProvider.addExtendedOperationHandler( h );
             log.info( "Added Extended Request Handler: " + h.getOid() );
-            
-            if ( h instanceof GracefulShutdownHandler )
-            {
-                GracefulShutdownHandler graceful = ( GracefulShutdownHandler ) h;
-                graceful.setLdapService( service );
-                graceful.setServiceRegistry( minaRegistry );
-            }
-            else if ( h instanceof LaunchDiagnosticUiHandler )
-            {
-                LaunchDiagnosticUiHandler diagnostic = ( LaunchDiagnosticUiHandler ) h;
-                diagnostic.setLdapService( service );
-                diagnostic.setServiceRegistry( minaRegistry );
-                diagnostic.setLdapProvider( protocolProvider );
-            }
+            h.setLdapService( service );
+            h.setServiceRegistry( minaRegistry );
+            h.setLdapProvider( protocolProvider );
+            DirectoryPartitionNexus nexus = directoryService.getConfiguration().getPartitionNexus();
+            nexus.registerSupportedExtensions( h.getExtensionOids() );
         }
         
         try

Modified: directory/trunks/apacheds/tools/src/test/java/org/apache/ldap/server/dumptool/NotificationsExample.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/tools/src/test/java/org/apache/ldap/server/dumptool/NotificationsExample.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/apacheds/tools/src/test/java/org/apache/ldap/server/dumptool/NotificationsExample.java
(original)
+++ directory/trunks/apacheds/tools/src/test/java/org/apache/ldap/server/dumptool/NotificationsExample.java
Mon Jan 30 20:54:10 2006
@@ -71,15 +71,15 @@
     {
         notification = evt.getNotification();
         
-        if ( notification.getID().equals( NoticeOfDisconnect.OID ) )
+        if ( notification.getID().equals( NoticeOfDisconnect.EXTENSION_OID ) )
         {
-            System.out.println( "\nRecieved NoticeOfDisconnect: " + NoticeOfDisconnect.OID
);
+            System.out.println( "\nRecieved NoticeOfDisconnect: " + NoticeOfDisconnect.EXTENSION_OID
);
             System.out.println( "Expect to loose this connection without further information."
);
             canceled = true;
         }
-        else if ( notification.getID().equals( GracefulDisconnect.OID ) )
+        else if ( notification.getID().equals( GracefulDisconnect.EXTENSION_OID ) )
         {
-            System.out.println( "Recieved GracefulDisconnect: " + GracefulDisconnect.OID
);
+            System.out.println( "Recieved GracefulDisconnect: " + GracefulDisconnect.EXTENSION_OID
);
             GracefulDisconnect gd = new GracefulDisconnect( notification.getEncodedValue()
);
             System.out.println( "LDAP server will shutdown in " + gd.getDelay() + " seconds."
);
             System.out.println( "LDAP server will be back online in " + gd.getTimeOffline()
+ " minutes." );

Modified: directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/GracefulDisconnect.java
URL: http://svn.apache.org/viewcvs/directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/GracefulDisconnect.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/GracefulDisconnect.java
(original)
+++ directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/GracefulDisconnect.java
Mon Jan 30 20:54:10 2006
@@ -50,7 +50,7 @@
 public class GracefulDisconnect extends ExtendedResponseImpl
 {
     private static final long serialVersionUID = -4682291068700593492L;
-    public static final String OID = "1.2.6.1.4.1.18060.1.1.1.100.5";
+    public static final String EXTENSION_OID = "1.2.6.1.4.1.18060.1.1.1.100.5";
     private static final Logger log = LoggerFactory.getLogger( GracefulDisconnect.class );
     
     /** offline Time after disconnection */
@@ -74,7 +74,7 @@
     public GracefulDisconnect( int timeOffline, int delay )
     {
         super( 0 );
-        super.oid = OID;
+        super.oid = EXTENSION_OID;
         this.timeOffline = timeOffline;
         this.delay = delay;
         
@@ -209,7 +209,7 @@
      */
     public String getResponseName()
     {
-        return OID;
+        return EXTENSION_OID;
     }
 
 
@@ -221,7 +221,7 @@
      */
     public void setResponseName( String oid )
     {
-        throw new UnsupportedOperationException( "the OID is fixed: " + OID );
+        throw new UnsupportedOperationException( "the OID is fixed: " + EXTENSION_OID );
     }
 
 

Modified: directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/NoticeOfDisconnect.java
URL: http://svn.apache.org/viewcvs/directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/NoticeOfDisconnect.java?rev=373703&r1=373702&r2=373703&view=diff
==============================================================================
--- directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/NoticeOfDisconnect.java
(original)
+++ directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/message/extended/NoticeOfDisconnect.java
Mon Jan 30 20:54:10 2006
@@ -99,7 +99,7 @@
 public class NoticeOfDisconnect extends ExtendedResponseImpl
 {
     private static final long serialVersionUID = -4682291068700593492L;
-    public static final String OID = "1.3.6.1.4.1.1466.20036";
+    public static final String EXTENSION_OID = "1.3.6.1.4.1.1466.20036";
     private static final byte[] EMPTY_RESPONSE = new byte[0];
     
     public static NoticeOfDisconnect UNAVAILABLE = new NoticeOfDisconnect( ResultCodeEnum.UNAVAILABLE
);
@@ -166,7 +166,7 @@
      */
     public String getResponseName()
     {
-        return OID;
+        return EXTENSION_OID;
     }
 
 
@@ -178,7 +178,7 @@
      */
     public void setResponseName( String oid )
     {
-        throw new UnsupportedOperationException( "the OID is fixed: " + OID );
+        throw new UnsupportedOperationException( "the OID is fixed: " + EXTENSION_OID );
     }
 
 



Mime
View raw message