directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r679337 - /directory/apacheds/branches/bigbang/protocol-newldap/src/main/java/org/apache/directory/server/newldap/handlers/extended/StoredProcedureExtendedOperationHandler.java
Date Thu, 24 Jul 2008 10:12:14 GMT
Author: elecharny
Date: Thu Jul 24 03:12:13 2008
New Revision: 679337

URL: http://svn.apache.org/viewvc?rev=679337&view=rev
Log:
Fixed a compilation error (a JNDI has been removed, we should access to data through CoreSession)

Modified:
    directory/apacheds/branches/bigbang/protocol-newldap/src/main/java/org/apache/directory/server/newldap/handlers/extended/StoredProcedureExtendedOperationHandler.java

Modified: directory/apacheds/branches/bigbang/protocol-newldap/src/main/java/org/apache/directory/server/newldap/handlers/extended/StoredProcedureExtendedOperationHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-newldap/src/main/java/org/apache/directory/server/newldap/handlers/extended/StoredProcedureExtendedOperationHandler.java?rev=679337&r1=679336&r2=679337&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-newldap/src/main/java/org/apache/directory/server/newldap/handlers/extended/StoredProcedureExtendedOperationHandler.java
(original)
+++ directory/apacheds/branches/bigbang/protocol-newldap/src/main/java/org/apache/directory/server/newldap/handlers/extended/StoredProcedureExtendedOperationHandler.java
Thu Jul 24 03:12:13 2008
@@ -27,15 +27,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.ldap.LdapContext;
-
 import org.apache.commons.lang.SerializationUtils;
 import org.apache.directory.server.core.entry.ClonedServerEntry;
-import org.apache.directory.server.core.jndi.ServerLdapContext;
 import org.apache.directory.server.core.sp.StoredProcEngine;
 import org.apache.directory.server.core.sp.StoredProcEngineConfig;
 import org.apache.directory.server.core.sp.StoredProcExecutionManager;
@@ -92,20 +88,16 @@
         StoredProcEngine engine = manager.getStoredProcEngineInstance( spUnit );
         
         List<Object> valueList = new ArrayList<Object>( spBean.getParameters().size()
);
-        Iterator<StoredProcedureParameter> it = spBean.getParameters().iterator();
-        LdapContext ctx = new ServerLdapContext( session.getCoreSession().getDirectoryService(),
-            session.getCoreSession().getEffectivePrincipal(), new LdapDN() );
         
-        while ( it.hasNext() )
+        for ( StoredProcedureParameter pPojo:spBean.getParameters() )
         {
-            StoredProcedureParameter pPojo = it.next();
             byte[] serializedValue = pPojo.getValue();
             Object value = SerializationUtils.deserialize( serializedValue );
             
             if ( value.getClass().equals( LdapContextParameter.class ) )
             {
                 String paramCtx = ( ( LdapContextParameter ) value ).getValue();
-                value = ctx.lookup( paramCtx );
+                value = session.getCoreSession().lookup( new LdapDN( paramCtx ) );
             }
             
             valueList.add( value );



Mime
View raw message