commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jcar...@apache.org
Subject svn commit: r279571 - in /jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy: factory/util/ interceptor/ provider/
Date Thu, 08 Sep 2005 15:07:35 GMT
Author: jcarman
Date: Thu Sep  8 08:07:28 2005
New Revision: 279571

URL: http://svn.apache.org/viewcvs?rev=279571&view=rev
Log:
Removed runtime dependency on Jakarta Commons Logging.

Removed:
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/AbstractMethodInterceptor.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/AbstractObjectProvider.java
Modified:
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/factory/util/AbstractProxyFactory.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/ExecutorMethodInterceptor.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/MethodInterceptorChain.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BeanProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BurlapProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ConstantProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/HessianProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/JaxRpcProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/PooledProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ProviderDecorator.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/RmiProvider.java
    jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/SessionBeanProvider.java

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/factory/util/AbstractProxyFactory.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/factory/util/AbstractProxyFactory.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/factory/util/AbstractProxyFactory.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/factory/util/AbstractProxyFactory.java
Thu Sep  8 08:07:28 2005
@@ -17,8 +17,6 @@
 package org.apache.commons.proxy.factory.util;
 
 import org.aopalliance.intercept.MethodInterceptor;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
 import org.apache.commons.proxy.ObjectProvider;
 import org.apache.commons.proxy.ProxyFactory;
 
@@ -33,31 +31,12 @@
 public abstract class AbstractProxyFactory implements ProxyFactory
 {
 //----------------------------------------------------------------------------------------------------------------------
-// Fields
-//----------------------------------------------------------------------------------------------------------------------
-
-    protected Log log;
-
-//----------------------------------------------------------------------------------------------------------------------
-// Constructors
-//----------------------------------------------------------------------------------------------------------------------
-
-    protected AbstractProxyFactory()
-    {
-        setLog( LogFactory.getLog( getClass() ) );
-    }
-
-    public void setLog( Log log )
-    {
-        this.log = log;
-    }
-
-//----------------------------------------------------------------------------------------------------------------------
 // ProxyFactory Implementation
 //----------------------------------------------------------------------------------------------------------------------
 
     /**
      * Returns true if all <code>proxyClasses</code> are interfaces.
+     *
      * @param proxyClasses the proxy classes
      * @return true if all <code>proxyClasses</code> are interfaces
      */

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/ExecutorMethodInterceptor.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/ExecutorMethodInterceptor.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/ExecutorMethodInterceptor.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/ExecutorMethodInterceptor.java
Thu Sep  8 08:07:28 2005
@@ -17,6 +17,7 @@
 package org.apache.commons.proxy.interceptor;
 
 import org.aopalliance.intercept.MethodInvocation;
+import org.aopalliance.intercept.MethodInterceptor;
 
 import java.util.concurrent.Executor;
 
@@ -31,7 +32,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class ExecutorMethodInterceptor extends AbstractMethodInterceptor
+public class ExecutorMethodInterceptor implements MethodInterceptor
 {
     private final Executor executor;
 
@@ -58,7 +59,7 @@
                         }
                         catch( Throwable t )
                         {
-                            getLog().error( "Method invocation threw an exception.", t );
+                            // What to do here?  I can't convey the failure back to the caller.
                         }
                     }
                 } );

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/MethodInterceptorChain.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/MethodInterceptorChain.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/MethodInterceptorChain.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/interceptor/MethodInterceptorChain.java
Thu Sep  8 08:07:28 2005
@@ -20,11 +20,6 @@
 import org.apache.commons.proxy.ObjectProvider;
 import org.apache.commons.proxy.ProxyFactory;
 import org.apache.commons.proxy.ProxyUtils;
-import org.apache.commons.proxy.provider.AbstractObjectProvider;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
 
 /**
  * A <code>MethodInterceptorChain</code> assists with creating proxies which
go through a series of
@@ -87,7 +82,7 @@
 // Inner Classes
 //----------------------------------------------------------------------------------------------------------------------
 
-    private class ProxyObjectProvider extends AbstractObjectProvider
+    private class ProxyObjectProvider implements ObjectProvider
     {
         private final ClassLoader classLoader;
         private final Class[] proxyClasses;

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BeanProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BeanProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BeanProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BeanProvider.java
Thu Sep  8 08:07:28 2005
@@ -17,6 +17,7 @@
 package org.apache.commons.proxy.provider;
 
 import org.apache.commons.proxy.exception.ObjectProviderException;
+import org.apache.commons.proxy.ObjectProvider;
 
 /**
  * Uses <code>Class.newInstance()</code> to instantiate an object.
@@ -24,7 +25,7 @@
  * @author James Carman
  * @version $Rev: 57 $
  */
-public class BeanProvider extends AbstractObjectProvider
+public class BeanProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BurlapProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BurlapProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BurlapProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/BurlapProvider.java
Thu Sep  8 08:07:28 2005
@@ -18,6 +18,7 @@
 
 import com.caucho.burlap.client.BurlapProxyFactory;
 import org.apache.commons.proxy.exception.ObjectProviderException;
+import org.apache.commons.proxy.ObjectProvider;
 
 import java.net.MalformedURLException;
 
@@ -27,7 +28,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class BurlapProvider extends AbstractObjectProvider
+public class BurlapProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ConstantProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ConstantProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ConstantProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ConstantProvider.java
Thu Sep  8 08:07:28 2005
@@ -16,13 +16,15 @@
  */
 package org.apache.commons.proxy.provider;
 
+import org.apache.commons.proxy.ObjectProvider;
+
 /**
  * Always returns the same object.
  *
  * @author James Carman
  * @version 1.0
  */
-public class ConstantProvider extends AbstractObjectProvider
+public class ConstantProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/HessianProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/HessianProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/HessianProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/HessianProvider.java
Thu Sep  8 08:07:28 2005
@@ -18,6 +18,7 @@
 
 import com.caucho.hessian.client.HessianProxyFactory;
 import org.apache.commons.proxy.exception.ObjectProviderException;
+import org.apache.commons.proxy.ObjectProvider;
 
 import java.net.MalformedURLException;
 
@@ -27,7 +28,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class HessianProvider extends AbstractObjectProvider
+public class HessianProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/JaxRpcProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/JaxRpcProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/JaxRpcProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/JaxRpcProvider.java
Thu Sep  8 08:07:28 2005
@@ -17,6 +17,7 @@
 package org.apache.commons.proxy.provider;
 
 import org.apache.commons.proxy.exception.ObjectProviderException;
+import org.apache.commons.proxy.ObjectProvider;
 
 import javax.xml.namespace.QName;
 import javax.xml.rpc.Service;
@@ -31,7 +32,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class JaxRpcProvider extends AbstractObjectProvider
+public class JaxRpcProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/PooledProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/PooledProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/PooledProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/PooledProvider.java
Thu Sep  8 08:07:28 2005
@@ -33,7 +33,6 @@
 //----------------------------------------------------------------------------------------------------------------------
 // Fields
 //----------------------------------------------------------------------------------------------------------------------
-
     private final Object cacheKey = new Object();
     private final GenericObjectPool pool;
     private Cache cache;
@@ -56,7 +55,6 @@
     {
         try
         {
-            log.debug( "Returning object to pool in thread " + Thread.currentThread().getName()
+ "..." );
             pool.returnObject( e.getEvictedObject() );
         }
         catch( Exception e1 )
@@ -73,12 +71,9 @@
     {
         try
         {
-            log.debug( "Checking for object in cache in thread " + Thread.currentThread().getName()
+ "..." );
             Object object = cache.retrieveObject( cacheKey );
             if( object == null )
             {
-                log.debug( "Did not object in cache; borrowing from pool in thread " +
-                           Thread.currentThread().getName() + "..." );
                 object = pool.borrowObject();
                 cache.storeObject( cacheKey, object, this );
             }
@@ -166,7 +161,6 @@
     {
         public Object makeObject() throws Exception
         {
-            log.debug( "Creating new object for pool in thread " + Thread.currentThread().getName()
+ "..." );
             return inner.getObject();
         }
     }

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ProviderDecorator.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ProviderDecorator.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ProviderDecorator.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/ProviderDecorator.java
Thu Sep  8 08:07:28 2005
@@ -22,7 +22,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class ProviderDecorator extends AbstractObjectProvider
+public class ProviderDecorator implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/RmiProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/RmiProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/RmiProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/RmiProvider.java
Thu Sep  8 08:07:28 2005
@@ -17,6 +17,7 @@
 package org.apache.commons.proxy.provider;
 
 import org.apache.commons.proxy.exception.ObjectProviderException;
+import org.apache.commons.proxy.ObjectProvider;
 
 import java.rmi.AccessException;
 import java.rmi.NotBoundException;
@@ -31,7 +32,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class RmiProvider extends AbstractObjectProvider
+public class RmiProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields
@@ -129,13 +130,10 @@
         {
             if( clientSocketFactory != null )
             {
-                log.debug( "Looking up RMI registry at " + host + ":" + port +
-                           " using specified client socket factory..." );
                 return LocateRegistry.getRegistry( host, port, clientSocketFactory );
             }
             else
             {
-                log.debug( "Looking up RMI registry at " + host + ":" + port + "..." );
                 return LocateRegistry.getRegistry( host, port );
             }
         }

Modified: jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/SessionBeanProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/SessionBeanProvider.java?rev=279571&r1=279570&r2=279571&view=diff
==============================================================================
--- jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/SessionBeanProvider.java
(original)
+++ jakarta/commons/sandbox/proxy/trunk/src/java/org/apache/commons/proxy/provider/SessionBeanProvider.java
Thu Sep  8 08:07:28 2005
@@ -17,6 +17,7 @@
 package org.apache.commons.proxy.provider;
 
 import org.apache.commons.proxy.exception.ObjectProviderException;
+import org.apache.commons.proxy.ObjectProvider;
 
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
@@ -31,7 +32,7 @@
  * @author James Carman
  * @version 1.0
  */
-public class SessionBeanProvider extends AbstractObjectProvider
+public class SessionBeanProvider implements ObjectProvider
 {
 //----------------------------------------------------------------------------------------------------------------------
 // Fields



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message