commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1570993 [6/24] - in /commons/proper/jcs/trunk/src: assembly/ changes/ conf/ java/org/apache/commons/jcs/access/ java/org/apache/commons/jcs/access/exception/ java/org/apache/commons/jcs/admin/ java/org/apache/commons/jcs/auxiliary/ java/or...
Date Sun, 23 Feb 2014 10:37:52 GMT
Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/AbstractRemoteCacheNoWaitFacade.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/AbstractRemoteCacheNoWaitFacade.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/AbstractRemoteCacheNoWaitFacade.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/AbstractRemoteCacheNoWaitFacade.java Sun Feb 23 10:37:48 2014
@@ -1,473 +1,473 @@
-package org.apache.commons.jcs.auxiliary.remote;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.IOException;
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import org.apache.commons.jcs.auxiliary.AbstractAuxiliaryCache;
-import org.apache.commons.jcs.auxiliary.AuxiliaryCache;
-import org.apache.commons.jcs.auxiliary.AuxiliaryCacheAttributes;
-import org.apache.commons.jcs.auxiliary.remote.behavior.IRemoteCacheAttributes;
-import org.apache.commons.jcs.engine.CacheStatus;
-import org.apache.commons.jcs.engine.behavior.ICacheElement;
-import org.apache.commons.jcs.engine.behavior.ICompositeCacheManager;
-import org.apache.commons.jcs.engine.behavior.IElementSerializer;
-import org.apache.commons.jcs.engine.logging.behavior.ICacheEventLogger;
-import org.apache.commons.jcs.engine.stats.StatElement;
-import org.apache.commons.jcs.engine.stats.Stats;
-import org.apache.commons.jcs.engine.stats.behavior.IStatElement;
-import org.apache.commons.jcs.engine.stats.behavior.IStats;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-/** An abstract base for the No Wait Facade.  Different implementations will failover differently. */
-public abstract class AbstractRemoteCacheNoWaitFacade<K extends Serializable, V extends Serializable>
-    extends AbstractAuxiliaryCache<K, V>
-{
-    /** For serialization. Don't change. */
-    private static final long serialVersionUID = -4529970797620747110L;
-
-    /** log instance */
-    private final static Log log = LogFactory.getLog( AbstractRemoteCacheNoWaitFacade.class );
-
-    /** The connection to a remote server, or a zombie. */
-    public RemoteCacheNoWait<K, V>[] noWaits;
-
-    /** The cache name */
-    private final String cacheName;
-
-    /** holds failover and cluster information */
-    protected IRemoteCacheAttributes remoteCacheAttributes;
-
-    /** A cache manager */
-    private ICompositeCacheManager compositeCacheManager;
-
-    /**
-     * Constructs with the given remote cache, and fires events to any listeners.
-     * <p>
-     * @param noWaits
-     * @param rca
-     * @param cacheMgr
-     * @param cacheEventLogger
-     * @param elementSerializer
-     */
-    public AbstractRemoteCacheNoWaitFacade( RemoteCacheNoWait<K, V>[] noWaits, RemoteCacheAttributes rca,
-                                    ICompositeCacheManager cacheMgr, ICacheEventLogger cacheEventLogger,
-                                    IElementSerializer elementSerializer )
-    {
-        if ( log.isDebugEnabled() )
-        {
-            log.debug( "CONSTRUCTING NO WAIT FACADE" );
-        }
-        this.noWaits = noWaits;
-        this.remoteCacheAttributes = rca;
-        this.cacheName = rca.getCacheName();
-        setCompositeCacheManager( cacheMgr );
-        this.cacheEventLogger = cacheEventLogger;
-        this.elementSerializer = elementSerializer;
-    }
-
-    /**
-     * Put an element in the cache.
-     * <p>
-     * @param ce
-     * @throws IOException
-     */
-    public void update( ICacheElement<K, V> ce )
-        throws IOException
-    {
-        if ( log.isDebugEnabled() )
-        {
-            log.debug( "updating through cache facade, noWaits.length = " + noWaits.length );
-        }
-        int i = 0;
-        try
-        {
-            for ( ; i < noWaits.length; i++ )
-            {
-                noWaits[i].update( ce );
-                // an initial move into a zombie will lock this to primary
-                // recovery. will not discover other servers until primary
-                // reconnect
-                // and subsequent error
-            }
-        }
-        catch ( Exception ex )
-        {
-            String message = "Problem updating no wait.  Will initiate failover if the noWait is in error.";
-            log.error( message, ex );
-
-            if ( getCacheEventLogger() != null )
-            {
-                getCacheEventLogger().logError(
-                                                "RemoteCacheNoWaitFacade",
-                                                ICacheEventLogger.UPDATE_EVENT,
-                                                message + ":" + ex.getMessage() + " REGION: " + ce.getCacheName()
-                                                    + " ELEMENT: " + ce );
-            }
-
-            // can handle failover here? Is it safe to try the others?
-            // check to see it the noWait is now a zombie
-            // if it is a zombie, then move to the next in the failover list
-            // will need to keep them in order or a count
-            failover( i );
-            // should start a failover thread
-            // should probably only failover if there is only one in the noWait
-            // list
-            // Should start a background thread to restore the original primary if we are in failover state.
-        }
-    }
-
-    /**
-     * Synchronously reads from the remote cache.
-     * <p>
-     * @param key
-     * @return Either an ICacheElement<K, V> or null if it is not found.
-     */
-    public ICacheElement<K, V> get( K key )
-    {
-        for ( int i = 0; i < noWaits.length; i++ )
-        {
-            try
-            {
-                ICacheElement<K, V> obj = noWaits[i].get( key );
-                if ( obj != null )
-                {
-                    return obj;
-                }
-            }
-            catch ( IOException ex )
-            {
-                log.debug( "Failed to get." );
-                return null;
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Synchronously read from the remote cache.
-     * <p>
-     * @param pattern
-     * @return map
-     * @throws IOException
-     */
-    public Map<K, ICacheElement<K, V>> getMatching( String pattern )
-        throws IOException
-    {
-        for ( int i = 0; i < noWaits.length; i++ )
-        {
-            try
-            {
-                return noWaits[i].getMatching( pattern );
-            }
-            catch ( IOException ex )
-            {
-                log.debug( "Failed to getMatching." );
-            }
-        }
-        return Collections.emptyMap();
-    }
-
-    /**
-     * Gets multiple items from the cache based on the given set of keys.
-     * <p>
-     * @param keys
-     * @return a map of K key to ICacheElement<K, V> element, or an empty map if there is no
-     *         data in cache for any of these keys
-     */
-    public Map<K, ICacheElement<K, V>> getMultiple( Set<K> keys )
-    {
-        if ( keys != null && !keys.isEmpty() )
-        {
-            for ( int i = 0; i < noWaits.length; i++ )
-            {
-                try
-                {
-                    return noWaits[i].getMultiple( keys );
-                }
-                catch ( IOException ex )
-                {
-                    log.debug( "Failed to get." );
-                }
-            }
-        }
-
-        return Collections.emptyMap();
-    }
-
-    /**
-     * Return the keys in this cache.
-     * <p>
-     * @see org.apache.commons.jcs.auxiliary.AuxiliaryCache#getKeySet()
-     */
-    public Set<K> getKeySet() throws IOException
-    {
-        HashSet<K> allKeys = new HashSet<K>();
-        for ( int i = 0; i < noWaits.length; i++ )
-        {
-            AuxiliaryCache<K, V> aux = noWaits[i];
-            if ( aux != null )
-            {
-                Set<K> keys = aux.getKeySet();
-                if(keys != null)
-                {
-                    allKeys.addAll( keys );
-                }
-            }
-        }
-        return allKeys;
-    }
-
-    /**
-     * Adds a remove request to the remote cache.
-     * <p>
-     * @param key
-     * @return whether or not it was removed, right now it return false.
-     */
-    public boolean remove( K key )
-    {
-        try
-        {
-            for ( int i = 0; i < noWaits.length; i++ )
-            {
-                noWaits[i].remove( key );
-            }
-        }
-        catch ( Exception ex )
-        {
-            log.error( ex );
-        }
-        return false;
-    }
-
-    /**
-     * Adds a removeAll request to the remote cache.
-     */
-    public void removeAll()
-    {
-        try
-        {
-            for ( int i = 0; i < noWaits.length; i++ )
-            {
-                noWaits[i].removeAll();
-            }
-        }
-        catch ( Exception ex )
-        {
-            log.error( ex );
-        }
-    }
-
-    /** Adds a dispose request to the remote cache. */
-    public void dispose()
-    {
-        try
-        {
-            for ( int i = 0; i < noWaits.length; i++ )
-            {
-                noWaits[i].dispose();
-            }
-        }
-        catch ( Exception ex )
-        {
-            log.error( "Problem in dispose.", ex );
-        }
-    }
-
-    /**
-     * No remote invocation.
-     * <p>
-     * @return The size value
-     */
-    public int getSize()
-    {
-        return 0;
-        // cache.getSize();
-    }
-
-    /**
-     * Gets the cacheType attribute of the RemoteCacheNoWaitFacade object.
-     * <p>
-     * @return The cacheType value
-     */
-    public CacheType getCacheType()
-    {
-        return CacheType.REMOTE_CACHE;
-    }
-
-    /**
-     * Gets the cacheName attribute of the RemoteCacheNoWaitFacade object.
-     * <p>
-     * @return The cacheName value
-     */
-    public String getCacheName()
-    {
-        return remoteCacheAttributes.getCacheName();
-    }
-
-    /**
-     * Gets the status attribute of the RemoteCacheNoWaitFacade object
-     * <p>
-     * Return ALIVE if any are alive.
-     * <p>
-     * @return The status value
-     */
-    public CacheStatus getStatus()
-    {
-        for ( int i = 0; i < noWaits.length; i++ )
-        {
-            if ( noWaits[i].getStatus() == CacheStatus.ALIVE )
-            {
-                return CacheStatus.ALIVE;
-            }
-        }
-
-        return CacheStatus.DISPOSED;
-    }
-
-    /**
-     * String form of some of the configuration information for the remote cache.
-     * <p>
-     * @return Some info for logging.
-     */
-    @Override
-    public String toString()
-    {
-        return "RemoteCacheNoWaitFacade: " + cacheName + ", rca = " + remoteCacheAttributes;
-    }
-
-    /**
-     * Begin the failover process if this is a local cache. Clustered remote caches do not failover.
-     * <p>
-     * @param i The no wait in error.
-     */
-    abstract void failover( int i );
-
-
-    /**
-     * @return Returns the AuxiliaryCacheAttributes.
-     */
-    public AuxiliaryCacheAttributes getAuxiliaryCacheAttributes()
-    {
-        return this.remoteCacheAttributes;
-    }
-
-    /**
-     * getStats
-     * @return String
-     */
-    public String getStats()
-    {
-        return getStatistics().toString();
-    }
-
-    /**
-     * @return statistics about the cache region
-     */
-    public IStats getStatistics()
-    {
-        IStats stats = new Stats();
-        stats.setTypeName( "Remote Cache No Wait Facade" );
-
-        ArrayList<IStatElement> elems = new ArrayList<IStatElement>();
-
-        IStatElement se = null;
-
-        if ( noWaits != null )
-        {
-            se = new StatElement();
-            se.setName( "Number of No Waits" );
-            se.setData( "" + noWaits.length );
-            elems.add( se );
-
-            for ( int i = 0; i < noWaits.length; i++ )
-            {
-                // get the stats from the super too
-                // get as array, convert to list, add list to our outer list
-                IStats sStats = noWaits[i].getStatistics();
-                IStatElement[] sSEs = sStats.getStatElements();
-                List<IStatElement> sL = Arrays.asList( sSEs );
-                elems.addAll( sL );
-            }
-        }
-
-        // get an array and put them in the Stats object
-        IStatElement[] ses = elems.toArray( new StatElement[0] );
-        stats.setStatElements( ses );
-
-        return stats;
-    }
-
-    /**
-     * This typically returns end point info .
-     * <p>
-     * @return the name
-     */
-    @Override
-    public String getEventLoggingExtraInfo()
-    {
-        return "Remote Cache No Wait Facade";
-    }
-
-    /**
-     * Gets the remoteCacheAttributes attribute of the RemoteCacheNoWaitFacade object
-     * <p>
-     * @return The remoteCacheAttributes value
-     */
-    public IRemoteCacheAttributes getRemoteCacheAttributes()
-    {
-        return remoteCacheAttributes;
-    }
-
-    /**
-     * Sets the remoteCacheAttributes attribute of the RemoteCacheNoWaitFacade object.
-     * <p>
-     * @param rca The new remoteCacheAttributes value
-     */
-    public void setRemoteCacheAttributes( IRemoteCacheAttributes rca )
-    {
-        this.remoteCacheAttributes = rca;
-    }
-
-    /**
-     * @param compositeCacheManager the compositeCacheManager to set
-     */
-    protected void setCompositeCacheManager( ICompositeCacheManager compositeCacheManager )
-    {
-        this.compositeCacheManager = compositeCacheManager;
-    }
-
-    /**
-     * @return the compositeCacheManager
-     */
-    protected ICompositeCacheManager getCompositeCacheManager()
-    {
-        return compositeCacheManager;
-    }
-}
+package org.apache.commons.jcs.auxiliary.remote;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.IOException;
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import org.apache.commons.jcs.auxiliary.AbstractAuxiliaryCache;
+import org.apache.commons.jcs.auxiliary.AuxiliaryCache;
+import org.apache.commons.jcs.auxiliary.AuxiliaryCacheAttributes;
+import org.apache.commons.jcs.auxiliary.remote.behavior.IRemoteCacheAttributes;
+import org.apache.commons.jcs.engine.CacheStatus;
+import org.apache.commons.jcs.engine.behavior.ICacheElement;
+import org.apache.commons.jcs.engine.behavior.ICompositeCacheManager;
+import org.apache.commons.jcs.engine.behavior.IElementSerializer;
+import org.apache.commons.jcs.engine.logging.behavior.ICacheEventLogger;
+import org.apache.commons.jcs.engine.stats.StatElement;
+import org.apache.commons.jcs.engine.stats.Stats;
+import org.apache.commons.jcs.engine.stats.behavior.IStatElement;
+import org.apache.commons.jcs.engine.stats.behavior.IStats;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/** An abstract base for the No Wait Facade.  Different implementations will failover differently. */
+public abstract class AbstractRemoteCacheNoWaitFacade<K extends Serializable, V extends Serializable>
+    extends AbstractAuxiliaryCache<K, V>
+{
+    /** For serialization. Don't change. */
+    private static final long serialVersionUID = -4529970797620747110L;
+
+    /** log instance */
+    private final static Log log = LogFactory.getLog( AbstractRemoteCacheNoWaitFacade.class );
+
+    /** The connection to a remote server, or a zombie. */
+    public RemoteCacheNoWait<K, V>[] noWaits;
+
+    /** The cache name */
+    private final String cacheName;
+
+    /** holds failover and cluster information */
+    protected IRemoteCacheAttributes remoteCacheAttributes;
+
+    /** A cache manager */
+    private ICompositeCacheManager compositeCacheManager;
+
+    /**
+     * Constructs with the given remote cache, and fires events to any listeners.
+     * <p>
+     * @param noWaits
+     * @param rca
+     * @param cacheMgr
+     * @param cacheEventLogger
+     * @param elementSerializer
+     */
+    public AbstractRemoteCacheNoWaitFacade( RemoteCacheNoWait<K, V>[] noWaits, RemoteCacheAttributes rca,
+                                    ICompositeCacheManager cacheMgr, ICacheEventLogger cacheEventLogger,
+                                    IElementSerializer elementSerializer )
+    {
+        if ( log.isDebugEnabled() )
+        {
+            log.debug( "CONSTRUCTING NO WAIT FACADE" );
+        }
+        this.noWaits = noWaits;
+        this.remoteCacheAttributes = rca;
+        this.cacheName = rca.getCacheName();
+        setCompositeCacheManager( cacheMgr );
+        this.cacheEventLogger = cacheEventLogger;
+        this.elementSerializer = elementSerializer;
+    }
+
+    /**
+     * Put an element in the cache.
+     * <p>
+     * @param ce
+     * @throws IOException
+     */
+    public void update( ICacheElement<K, V> ce )
+        throws IOException
+    {
+        if ( log.isDebugEnabled() )
+        {
+            log.debug( "updating through cache facade, noWaits.length = " + noWaits.length );
+        }
+        int i = 0;
+        try
+        {
+            for ( ; i < noWaits.length; i++ )
+            {
+                noWaits[i].update( ce );
+                // an initial move into a zombie will lock this to primary
+                // recovery. will not discover other servers until primary
+                // reconnect
+                // and subsequent error
+            }
+        }
+        catch ( Exception ex )
+        {
+            String message = "Problem updating no wait.  Will initiate failover if the noWait is in error.";
+            log.error( message, ex );
+
+            if ( getCacheEventLogger() != null )
+            {
+                getCacheEventLogger().logError(
+                                                "RemoteCacheNoWaitFacade",
+                                                ICacheEventLogger.UPDATE_EVENT,
+                                                message + ":" + ex.getMessage() + " REGION: " + ce.getCacheName()
+                                                    + " ELEMENT: " + ce );
+            }
+
+            // can handle failover here? Is it safe to try the others?
+            // check to see it the noWait is now a zombie
+            // if it is a zombie, then move to the next in the failover list
+            // will need to keep them in order or a count
+            failover( i );
+            // should start a failover thread
+            // should probably only failover if there is only one in the noWait
+            // list
+            // Should start a background thread to restore the original primary if we are in failover state.
+        }
+    }
+
+    /**
+     * Synchronously reads from the remote cache.
+     * <p>
+     * @param key
+     * @return Either an ICacheElement<K, V> or null if it is not found.
+     */
+    public ICacheElement<K, V> get( K key )
+    {
+        for ( int i = 0; i < noWaits.length; i++ )
+        {
+            try
+            {
+                ICacheElement<K, V> obj = noWaits[i].get( key );
+                if ( obj != null )
+                {
+                    return obj;
+                }
+            }
+            catch ( IOException ex )
+            {
+                log.debug( "Failed to get." );
+                return null;
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Synchronously read from the remote cache.
+     * <p>
+     * @param pattern
+     * @return map
+     * @throws IOException
+     */
+    public Map<K, ICacheElement<K, V>> getMatching( String pattern )
+        throws IOException
+    {
+        for ( int i = 0; i < noWaits.length; i++ )
+        {
+            try
+            {
+                return noWaits[i].getMatching( pattern );
+            }
+            catch ( IOException ex )
+            {
+                log.debug( "Failed to getMatching." );
+            }
+        }
+        return Collections.emptyMap();
+    }
+
+    /**
+     * Gets multiple items from the cache based on the given set of keys.
+     * <p>
+     * @param keys
+     * @return a map of K key to ICacheElement<K, V> element, or an empty map if there is no
+     *         data in cache for any of these keys
+     */
+    public Map<K, ICacheElement<K, V>> getMultiple( Set<K> keys )
+    {
+        if ( keys != null && !keys.isEmpty() )
+        {
+            for ( int i = 0; i < noWaits.length; i++ )
+            {
+                try
+                {
+                    return noWaits[i].getMultiple( keys );
+                }
+                catch ( IOException ex )
+                {
+                    log.debug( "Failed to get." );
+                }
+            }
+        }
+
+        return Collections.emptyMap();
+    }
+
+    /**
+     * Return the keys in this cache.
+     * <p>
+     * @see org.apache.commons.jcs.auxiliary.AuxiliaryCache#getKeySet()
+     */
+    public Set<K> getKeySet() throws IOException
+    {
+        HashSet<K> allKeys = new HashSet<K>();
+        for ( int i = 0; i < noWaits.length; i++ )
+        {
+            AuxiliaryCache<K, V> aux = noWaits[i];
+            if ( aux != null )
+            {
+                Set<K> keys = aux.getKeySet();
+                if(keys != null)
+                {
+                    allKeys.addAll( keys );
+                }
+            }
+        }
+        return allKeys;
+    }
+
+    /**
+     * Adds a remove request to the remote cache.
+     * <p>
+     * @param key
+     * @return whether or not it was removed, right now it return false.
+     */
+    public boolean remove( K key )
+    {
+        try
+        {
+            for ( int i = 0; i < noWaits.length; i++ )
+            {
+                noWaits[i].remove( key );
+            }
+        }
+        catch ( Exception ex )
+        {
+            log.error( ex );
+        }
+        return false;
+    }
+
+    /**
+     * Adds a removeAll request to the remote cache.
+     */
+    public void removeAll()
+    {
+        try
+        {
+            for ( int i = 0; i < noWaits.length; i++ )
+            {
+                noWaits[i].removeAll();
+            }
+        }
+        catch ( Exception ex )
+        {
+            log.error( ex );
+        }
+    }
+
+    /** Adds a dispose request to the remote cache. */
+    public void dispose()
+    {
+        try
+        {
+            for ( int i = 0; i < noWaits.length; i++ )
+            {
+                noWaits[i].dispose();
+            }
+        }
+        catch ( Exception ex )
+        {
+            log.error( "Problem in dispose.", ex );
+        }
+    }
+
+    /**
+     * No remote invocation.
+     * <p>
+     * @return The size value
+     */
+    public int getSize()
+    {
+        return 0;
+        // cache.getSize();
+    }
+
+    /**
+     * Gets the cacheType attribute of the RemoteCacheNoWaitFacade object.
+     * <p>
+     * @return The cacheType value
+     */
+    public CacheType getCacheType()
+    {
+        return CacheType.REMOTE_CACHE;
+    }
+
+    /**
+     * Gets the cacheName attribute of the RemoteCacheNoWaitFacade object.
+     * <p>
+     * @return The cacheName value
+     */
+    public String getCacheName()
+    {
+        return remoteCacheAttributes.getCacheName();
+    }
+
+    /**
+     * Gets the status attribute of the RemoteCacheNoWaitFacade object
+     * <p>
+     * Return ALIVE if any are alive.
+     * <p>
+     * @return The status value
+     */
+    public CacheStatus getStatus()
+    {
+        for ( int i = 0; i < noWaits.length; i++ )
+        {
+            if ( noWaits[i].getStatus() == CacheStatus.ALIVE )
+            {
+                return CacheStatus.ALIVE;
+            }
+        }
+
+        return CacheStatus.DISPOSED;
+    }
+
+    /**
+     * String form of some of the configuration information for the remote cache.
+     * <p>
+     * @return Some info for logging.
+     */
+    @Override
+    public String toString()
+    {
+        return "RemoteCacheNoWaitFacade: " + cacheName + ", rca = " + remoteCacheAttributes;
+    }
+
+    /**
+     * Begin the failover process if this is a local cache. Clustered remote caches do not failover.
+     * <p>
+     * @param i The no wait in error.
+     */
+    abstract void failover( int i );
+
+
+    /**
+     * @return Returns the AuxiliaryCacheAttributes.
+     */
+    public AuxiliaryCacheAttributes getAuxiliaryCacheAttributes()
+    {
+        return this.remoteCacheAttributes;
+    }
+
+    /**
+     * getStats
+     * @return String
+     */
+    public String getStats()
+    {
+        return getStatistics().toString();
+    }
+
+    /**
+     * @return statistics about the cache region
+     */
+    public IStats getStatistics()
+    {
+        IStats stats = new Stats();
+        stats.setTypeName( "Remote Cache No Wait Facade" );
+
+        ArrayList<IStatElement> elems = new ArrayList<IStatElement>();
+
+        IStatElement se = null;
+
+        if ( noWaits != null )
+        {
+            se = new StatElement();
+            se.setName( "Number of No Waits" );
+            se.setData( "" + noWaits.length );
+            elems.add( se );
+
+            for ( int i = 0; i < noWaits.length; i++ )
+            {
+                // get the stats from the super too
+                // get as array, convert to list, add list to our outer list
+                IStats sStats = noWaits[i].getStatistics();
+                IStatElement[] sSEs = sStats.getStatElements();
+                List<IStatElement> sL = Arrays.asList( sSEs );
+                elems.addAll( sL );
+            }
+        }
+
+        // get an array and put them in the Stats object
+        IStatElement[] ses = elems.toArray( new StatElement[0] );
+        stats.setStatElements( ses );
+
+        return stats;
+    }
+
+    /**
+     * This typically returns end point info .
+     * <p>
+     * @return the name
+     */
+    @Override
+    public String getEventLoggingExtraInfo()
+    {
+        return "Remote Cache No Wait Facade";
+    }
+
+    /**
+     * Gets the remoteCacheAttributes attribute of the RemoteCacheNoWaitFacade object
+     * <p>
+     * @return The remoteCacheAttributes value
+     */
+    public IRemoteCacheAttributes getRemoteCacheAttributes()
+    {
+        return remoteCacheAttributes;
+    }
+
+    /**
+     * Sets the remoteCacheAttributes attribute of the RemoteCacheNoWaitFacade object.
+     * <p>
+     * @param rca The new remoteCacheAttributes value
+     */
+    public void setRemoteCacheAttributes( IRemoteCacheAttributes rca )
+    {
+        this.remoteCacheAttributes = rca;
+    }
+
+    /**
+     * @param compositeCacheManager the compositeCacheManager to set
+     */
+    protected void setCompositeCacheManager( ICompositeCacheManager compositeCacheManager )
+    {
+        this.compositeCacheManager = compositeCacheManager;
+    }
+
+    /**
+     * @return the compositeCacheManager
+     */
+    protected ICompositeCacheManager getCompositeCacheManager()
+    {
+        return compositeCacheManager;
+    }
+}

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheAttributes.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheAttributes.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheAttributes.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheAttributes.java Sun Feb 23 10:37:48 2014
@@ -19,7 +19,6 @@ package org.apache.commons.jcs.auxiliary
  * under the License.
  */
 
-
 /**
  * This specifies what a remote cache configuration object should look like.
  */

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheConstants.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheConstants.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheConstants.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheConstants.java Sun Feb 23 10:37:48 2014
@@ -1,7 +1,5 @@
 package org.apache.commons.jcs.auxiliary.remote.behavior;
 
-import org.apache.commons.jcs.engine.behavior.ICacheServiceNonLocal;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -21,6 +19,9 @@ import org.apache.commons.jcs.engine.beh
  * under the License.
  */
 
+import org.apache.commons.jcs.engine.behavior.ICacheServiceNonLocal;
+
+
 /**
  * This holds constants that are used by the remote cache.
  */

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheDispatcher.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheDispatcher.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheDispatcher.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/behavior/IRemoteCacheDispatcher.java Sun Feb 23 10:37:48 2014
@@ -1,28 +1,47 @@
-package org.apache.commons.jcs.auxiliary.remote.behavior;
-
-import java.io.IOException;
-import java.io.Serializable;
-
-import org.apache.commons.jcs.auxiliary.remote.value.RemoteCacheRequest;
-import org.apache.commons.jcs.auxiliary.remote.value.RemoteCacheResponse;
-
-/**
- * In the future, this can be used as a generic dispatcher abstraction.
- * <p>
- * At the time of creation, only the http remote cache uses it. The RMI remote could be converted to
- * use it as well.
- */
-public interface IRemoteCacheDispatcher
-{
-    /**
-     * All requests will go through this method. The dispatcher implementation will send the request
-     * remotely.
-     * <p>
-     * @param remoteCacheRequest
-     * @return RemoteCacheResponse
-     * @throws IOException
-     */
-    <K extends Serializable, V extends Serializable, T>
-        RemoteCacheResponse<T> dispatchRequest( RemoteCacheRequest<K, V> remoteCacheRequest )
-            throws IOException;
-}
+package org.apache.commons.jcs.auxiliary.remote.behavior;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.IOException;
+import java.io.Serializable;
+
+import org.apache.commons.jcs.auxiliary.remote.value.RemoteCacheRequest;
+import org.apache.commons.jcs.auxiliary.remote.value.RemoteCacheResponse;
+
+/**
+ * In the future, this can be used as a generic dispatcher abstraction.
+ * <p>
+ * At the time of creation, only the http remote cache uses it. The RMI remote could be converted to
+ * use it as well.
+ */
+public interface IRemoteCacheDispatcher
+{
+    /**
+     * All requests will go through this method. The dispatcher implementation will send the request
+     * remotely.
+     * <p>
+     * @param remoteCacheRequest
+     * @return RemoteCacheResponse
+     * @throws IOException
+     */
+    <K extends Serializable, V extends Serializable, T>
+        RemoteCacheResponse<T> dispatchRequest( RemoteCacheRequest<K, V> remoteCacheRequest )
+            throws IOException;
+}

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/behavior/IRemoteHttpCacheConstants.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/behavior/IRemoteHttpCacheConstants.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/behavior/IRemoteHttpCacheConstants.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/behavior/IRemoteHttpCacheConstants.java Sun Feb 23 10:37:48 2014
@@ -1,31 +1,31 @@
-package org.apache.commons.jcs.auxiliary.remote.http.behavior;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-/** Constants used throughout the HTTP remote cache. */
-public interface IRemoteHttpCacheConstants
-{
-    /** The prefix for cache server config. */
-    String HTTP_CACHE_SERVER_PREFIX = "jcs.remotehttpcache";
-
-    /** All of the RemoteHttpCacheServiceAttributes can be configured this way. */
-    String HTTP_CACHE_SERVER_ATTRIBUTES_PROPERTY_PREFIX = HTTP_CACHE_SERVER_PREFIX
-        + ".serverattributes";
-}
+package org.apache.commons.jcs.auxiliary.remote.http.behavior;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/** Constants used throughout the HTTP remote cache. */
+public interface IRemoteHttpCacheConstants
+{
+    /** The prefix for cache server config. */
+    String HTTP_CACHE_SERVER_PREFIX = "jcs.remotehttpcache";
+
+    /** All of the RemoteHttpCacheServiceAttributes can be configured this way. */
+    String HTTP_CACHE_SERVER_ATTRIBUTES_PROPERTY_PREFIX = HTTP_CACHE_SERVER_PREFIX
+        + ".serverattributes";
+}

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/AbstractHttpClient.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/AbstractHttpClient.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/AbstractHttpClient.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/AbstractHttpClient.java Sun Feb 23 10:37:48 2014
@@ -1,193 +1,193 @@
-package org.apache.commons.jcs.auxiliary.remote.http.client;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.IOException;
-
-import org.apache.commons.httpclient.HttpClient;
-import org.apache.commons.httpclient.HttpMethod;
-import org.apache.commons.httpclient.HttpState;
-import org.apache.commons.httpclient.HttpVersion;
-import org.apache.commons.httpclient.MultiThreadedHttpConnectionManager;
-import org.apache.commons.httpclient.cookie.CookiePolicy;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-/**
- * This class simply configures the http multithreaded connection manager.
- * <p>
- * This is abstract because it can't do anything. Child classes can overwrite whatever they want.
- */
-public abstract class AbstractHttpClient
-{
-    /** The connection manager. */
-    private MultiThreadedHttpConnectionManager connectionManager;
-
-    /** The client */
-    private HttpClient httpClient;
-
-    /** Configuration settings. */
-    private RemoteHttpCacheAttributes remoteHttpCacheAttributes;
-
-    /** The Logger. */
-    private final static Log log = LogFactory.getLog( AbstractHttpClient.class );
-
-    /**
-     * Sets the default Properties File and Heading, and creates the HttpClient and connection
-     * manager.
-     * <p>
-     * @param remoteHttpCacheAttributes
-     */
-    public AbstractHttpClient( RemoteHttpCacheAttributes remoteHttpCacheAttributes )
-    {
-        setRemoteHttpCacheAttributes( remoteHttpCacheAttributes );
-        setConnectionManager( new MultiThreadedHttpConnectionManager() );
-
-        // THIS IS NOT THREAD SAFE:
-        // setHttpClient( new HttpClient() );
-        // THIS IS:
-        setHttpClient( new HttpClient( getConnectionManager() ) );
-
-        configureClient();
-    }
-
-    /**
-     * Configures the http client.
-     */
-    public void configureClient()
-    {
-        if ( getRemoteHttpCacheAttributes().getMaxConnectionsPerHost() > 0 )
-        {
-            getConnectionManager().getParams().setMaxTotalConnections(
-                                                                       getRemoteHttpCacheAttributes()
-                                                                           .getMaxConnectionsPerHost() );
-        }
-
-        getConnectionManager().getParams().setSoTimeout( getRemoteHttpCacheAttributes().getSocketTimeoutMillis() );
-
-        String httpVersion = getRemoteHttpCacheAttributes().getHttpVersion();
-        if ( httpVersion != null )
-        {
-            if ( "1.1".equals( httpVersion ) )
-            {
-                getHttpClient().getParams().setParameter( "http.protocol.version", HttpVersion.HTTP_1_1 );
-            }
-            else if ( "1.0".equals( httpVersion ) )
-            {
-                getHttpClient().getParams().setParameter( "http.protocol.version", HttpVersion.HTTP_1_0 );
-            }
-            else
-            {
-                log.warn( "Unrecognized value for 'httpVersion': [" + httpVersion + "]" );
-            }
-        }
-
-        getConnectionManager().getParams().setConnectionTimeout(
-                                                                 getRemoteHttpCacheAttributes()
-                                                                     .getConnectionTimeoutMillis() );
-
-        // By default we instruct HttpClient to ignore cookies.
-        String cookiePolicy = CookiePolicy.IGNORE_COOKIES;
-        getHttpClient().getParams().setCookiePolicy( cookiePolicy );
-    }
-
-    /**
-     * Extracted method that can be overwritten to do additional things to the post before the call
-     * is made.
-     * <p>
-     * @param post the post that is about to get executed.
-     * @throws IOException on i/o error
-     */
-    protected final void doWebserviceCall( HttpMethod post )
-        throws IOException
-    {
-        HttpState httpState = preProcessWebserviceCall( post );
-        getHttpClient().executeMethod( null, post, httpState );
-        postProcessWebserviceCall( post, httpState );
-    }
-
-    /**
-     * Called before the executeMethod on the client.
-     * <p>
-     * @param post http method
-     * @return HttpState
-     * @throws IOException
-     */
-    public abstract HttpState preProcessWebserviceCall( HttpMethod post )
-        throws IOException;
-
-    /**
-     * Called after the executeMethod on the client.
-     * <p>
-     * @param post http method
-     * @param httpState state
-     * @throws IOException
-     */
-    public abstract void postProcessWebserviceCall( HttpMethod post, HttpState httpState )
-        throws IOException;
-    
-    /**
-     * @return Returns the httpClient.
-     */
-    private HttpClient getHttpClient()
-    {
-        return httpClient;
-    }
-
-    /**
-     * @param httpClient The httpClient to set.
-     */
-    private void setHttpClient( HttpClient httpClient )
-    {
-        this.httpClient = httpClient;
-    }
-
-    /**
-     * @return Returns the connectionManager.
-     */
-    public MultiThreadedHttpConnectionManager getConnectionManager()
-    {
-        return connectionManager;
-    }
-
-    /**
-     * @param connectionManager The connectionManager to set.
-     */
-    public void setConnectionManager( MultiThreadedHttpConnectionManager connectionManager )
-    {
-        this.connectionManager = connectionManager;
-    }
-
-    /**
-     * @param remoteHttpCacheAttributes the remoteHttpCacheAttributes to set
-     */
-    public void setRemoteHttpCacheAttributes( RemoteHttpCacheAttributes remoteHttpCacheAttributes )
-    {
-        this.remoteHttpCacheAttributes = remoteHttpCacheAttributes;
-    }
-
-    /**
-     * @return the remoteHttpCacheAttributes
-     */
-    public RemoteHttpCacheAttributes getRemoteHttpCacheAttributes()
-    {
-        return remoteHttpCacheAttributes;
-    }
-}
+package org.apache.commons.jcs.auxiliary.remote.http.client;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.IOException;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.HttpMethod;
+import org.apache.commons.httpclient.HttpState;
+import org.apache.commons.httpclient.HttpVersion;
+import org.apache.commons.httpclient.MultiThreadedHttpConnectionManager;
+import org.apache.commons.httpclient.cookie.CookiePolicy;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * This class simply configures the http multithreaded connection manager.
+ * <p>
+ * This is abstract because it can't do anything. Child classes can overwrite whatever they want.
+ */
+public abstract class AbstractHttpClient
+{
+    /** The connection manager. */
+    private MultiThreadedHttpConnectionManager connectionManager;
+
+    /** The client */
+    private HttpClient httpClient;
+
+    /** Configuration settings. */
+    private RemoteHttpCacheAttributes remoteHttpCacheAttributes;
+
+    /** The Logger. */
+    private final static Log log = LogFactory.getLog( AbstractHttpClient.class );
+
+    /**
+     * Sets the default Properties File and Heading, and creates the HttpClient and connection
+     * manager.
+     * <p>
+     * @param remoteHttpCacheAttributes
+     */
+    public AbstractHttpClient( RemoteHttpCacheAttributes remoteHttpCacheAttributes )
+    {
+        setRemoteHttpCacheAttributes( remoteHttpCacheAttributes );
+        setConnectionManager( new MultiThreadedHttpConnectionManager() );
+
+        // THIS IS NOT THREAD SAFE:
+        // setHttpClient( new HttpClient() );
+        // THIS IS:
+        setHttpClient( new HttpClient( getConnectionManager() ) );
+
+        configureClient();
+    }
+
+    /**
+     * Configures the http client.
+     */
+    public void configureClient()
+    {
+        if ( getRemoteHttpCacheAttributes().getMaxConnectionsPerHost() > 0 )
+        {
+            getConnectionManager().getParams().setMaxTotalConnections(
+                                                                       getRemoteHttpCacheAttributes()
+                                                                           .getMaxConnectionsPerHost() );
+        }
+
+        getConnectionManager().getParams().setSoTimeout( getRemoteHttpCacheAttributes().getSocketTimeoutMillis() );
+
+        String httpVersion = getRemoteHttpCacheAttributes().getHttpVersion();
+        if ( httpVersion != null )
+        {
+            if ( "1.1".equals( httpVersion ) )
+            {
+                getHttpClient().getParams().setParameter( "http.protocol.version", HttpVersion.HTTP_1_1 );
+            }
+            else if ( "1.0".equals( httpVersion ) )
+            {
+                getHttpClient().getParams().setParameter( "http.protocol.version", HttpVersion.HTTP_1_0 );
+            }
+            else
+            {
+                log.warn( "Unrecognized value for 'httpVersion': [" + httpVersion + "]" );
+            }
+        }
+
+        getConnectionManager().getParams().setConnectionTimeout(
+                                                                 getRemoteHttpCacheAttributes()
+                                                                     .getConnectionTimeoutMillis() );
+
+        // By default we instruct HttpClient to ignore cookies.
+        String cookiePolicy = CookiePolicy.IGNORE_COOKIES;
+        getHttpClient().getParams().setCookiePolicy( cookiePolicy );
+    }
+
+    /**
+     * Extracted method that can be overwritten to do additional things to the post before the call
+     * is made.
+     * <p>
+     * @param post the post that is about to get executed.
+     * @throws IOException on i/o error
+     */
+    protected final void doWebserviceCall( HttpMethod post )
+        throws IOException
+    {
+        HttpState httpState = preProcessWebserviceCall( post );
+        getHttpClient().executeMethod( null, post, httpState );
+        postProcessWebserviceCall( post, httpState );
+    }
+
+    /**
+     * Called before the executeMethod on the client.
+     * <p>
+     * @param post http method
+     * @return HttpState
+     * @throws IOException
+     */
+    public abstract HttpState preProcessWebserviceCall( HttpMethod post )
+        throws IOException;
+
+    /**
+     * Called after the executeMethod on the client.
+     * <p>
+     * @param post http method
+     * @param httpState state
+     * @throws IOException
+     */
+    public abstract void postProcessWebserviceCall( HttpMethod post, HttpState httpState )
+        throws IOException;
+
+    /**
+     * @return Returns the httpClient.
+     */
+    private HttpClient getHttpClient()
+    {
+        return httpClient;
+    }
+
+    /**
+     * @param httpClient The httpClient to set.
+     */
+    private void setHttpClient( HttpClient httpClient )
+    {
+        this.httpClient = httpClient;
+    }
+
+    /**
+     * @return Returns the connectionManager.
+     */
+    public MultiThreadedHttpConnectionManager getConnectionManager()
+    {
+        return connectionManager;
+    }
+
+    /**
+     * @param connectionManager The connectionManager to set.
+     */
+    public void setConnectionManager( MultiThreadedHttpConnectionManager connectionManager )
+    {
+        this.connectionManager = connectionManager;
+    }
+
+    /**
+     * @param remoteHttpCacheAttributes the remoteHttpCacheAttributes to set
+     */
+    public void setRemoteHttpCacheAttributes( RemoteHttpCacheAttributes remoteHttpCacheAttributes )
+    {
+        this.remoteHttpCacheAttributes = remoteHttpCacheAttributes;
+    }
+
+    /**
+     * @return the remoteHttpCacheAttributes
+     */
+    public RemoteHttpCacheAttributes getRemoteHttpCacheAttributes()
+    {
+        return remoteHttpCacheAttributes;
+    }
+}

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCache.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCache.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCache.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCache.java Sun Feb 23 10:37:48 2014
@@ -1,120 +1,120 @@
-package org.apache.commons.jcs.auxiliary.remote.http.client;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import java.io.IOException;
-import java.io.Serializable;
-
-import org.apache.commons.jcs.auxiliary.remote.AbstractRemoteAuxiliaryCache;
-import org.apache.commons.jcs.auxiliary.remote.behavior.IRemoteCacheListener;
-import org.apache.commons.jcs.engine.ZombieCacheServiceNonLocal;
-import org.apache.commons.jcs.engine.behavior.ICacheServiceNonLocal;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-/**
- * This uses an http client as the service.
- */
-public class RemoteHttpCache<K extends Serializable, V extends Serializable>
-    extends AbstractRemoteAuxiliaryCache<K, V>
-{
-    /** Don't change. */
-    private static final long serialVersionUID = -5329231850422826461L;
-
-    /** The logger. */
-    private final static Log log = LogFactory.getLog( RemoteHttpCache.class );
-
-    /** Keep the child copy here for the restore process. */
-    private RemoteHttpCacheAttributes remoteHttpCacheAttributes;
-
-    /**
-     * Constructor for the RemoteCache object. This object communicates with a remote cache server.
-     * One of these exists for each region. This also holds a reference to a listener. The same
-     * listener is used for all regions for one remote server. Holding a reference to the listener
-     * allows this object to know the listener id assigned by the remote cache.
-     * <p>
-     * @param remoteHttpCacheAttributes
-     * @param remote
-     * @param listener
-     */
-    public RemoteHttpCache( RemoteHttpCacheAttributes remoteHttpCacheAttributes, ICacheServiceNonLocal<K, V> remote,
-                            IRemoteCacheListener<K, V> listener )
-    {
-        super( remoteHttpCacheAttributes, remote, listener );
-
-        setRemoteHttpCacheAttributes( remoteHttpCacheAttributes );
-    }
-
-    /**
-     * Nothing right now. This should setup a zombie and initiate recovery.
-     * <p>
-     * @param ex
-     * @param msg
-     * @param eventName
-     * @throws IOException
-     */
-    @Override
-    protected void handleException( Exception ex, String msg, String eventName )
-        throws IOException
-    {
-        // we should not switch if the existing is a zombie.
-        if ( !( getRemoteCacheService() instanceof ZombieCacheServiceNonLocal ) )
-        {
-            String message = "Disabling remote cache due to error: " + msg;
-            logError( cacheName, "", message );
-            log.error( message, ex );
-
-            setRemoteCacheService( new ZombieCacheServiceNonLocal<K, V>( getRemoteCacheAttributes().getZombieQueueMaxSize() ) );
-
-            RemoteHttpCacheMonitor.getInstance().notifyError( this );
-        }
-
-        if ( ex instanceof IOException )
-        {
-            throw (IOException) ex;
-        }
-        throw new IOException( ex.getMessage() );
-    }
-
-    /**
-     * @return url of service
-     */
-    @Override
-    public String getEventLoggingExtraInfo()
-    {
-        return null;
-    }
-
-    /**
-     * @param remoteHttpCacheAttributes the remoteHttpCacheAttributes to set
-     */
-    public void setRemoteHttpCacheAttributes( RemoteHttpCacheAttributes remoteHttpCacheAttributes )
-    {
-        this.remoteHttpCacheAttributes = remoteHttpCacheAttributes;
-    }
-
-    /**
-     * @return the remoteHttpCacheAttributes
-     */
-    public RemoteHttpCacheAttributes getRemoteHttpCacheAttributes()
-    {
-        return remoteHttpCacheAttributes;
-    }
-}
+package org.apache.commons.jcs.auxiliary.remote.http.client;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.IOException;
+import java.io.Serializable;
+
+import org.apache.commons.jcs.auxiliary.remote.AbstractRemoteAuxiliaryCache;
+import org.apache.commons.jcs.auxiliary.remote.behavior.IRemoteCacheListener;
+import org.apache.commons.jcs.engine.ZombieCacheServiceNonLocal;
+import org.apache.commons.jcs.engine.behavior.ICacheServiceNonLocal;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * This uses an http client as the service.
+ */
+public class RemoteHttpCache<K extends Serializable, V extends Serializable>
+    extends AbstractRemoteAuxiliaryCache<K, V>
+{
+    /** Don't change. */
+    private static final long serialVersionUID = -5329231850422826461L;
+
+    /** The logger. */
+    private final static Log log = LogFactory.getLog( RemoteHttpCache.class );
+
+    /** Keep the child copy here for the restore process. */
+    private RemoteHttpCacheAttributes remoteHttpCacheAttributes;
+
+    /**
+     * Constructor for the RemoteCache object. This object communicates with a remote cache server.
+     * One of these exists for each region. This also holds a reference to a listener. The same
+     * listener is used for all regions for one remote server. Holding a reference to the listener
+     * allows this object to know the listener id assigned by the remote cache.
+     * <p>
+     * @param remoteHttpCacheAttributes
+     * @param remote
+     * @param listener
+     */
+    public RemoteHttpCache( RemoteHttpCacheAttributes remoteHttpCacheAttributes, ICacheServiceNonLocal<K, V> remote,
+                            IRemoteCacheListener<K, V> listener )
+    {
+        super( remoteHttpCacheAttributes, remote, listener );
+
+        setRemoteHttpCacheAttributes( remoteHttpCacheAttributes );
+    }
+
+    /**
+     * Nothing right now. This should setup a zombie and initiate recovery.
+     * <p>
+     * @param ex
+     * @param msg
+     * @param eventName
+     * @throws IOException
+     */
+    @Override
+    protected void handleException( Exception ex, String msg, String eventName )
+        throws IOException
+    {
+        // we should not switch if the existing is a zombie.
+        if ( !( getRemoteCacheService() instanceof ZombieCacheServiceNonLocal ) )
+        {
+            String message = "Disabling remote cache due to error: " + msg;
+            logError( cacheName, "", message );
+            log.error( message, ex );
+
+            setRemoteCacheService( new ZombieCacheServiceNonLocal<K, V>( getRemoteCacheAttributes().getZombieQueueMaxSize() ) );
+
+            RemoteHttpCacheMonitor.getInstance().notifyError( this );
+        }
+
+        if ( ex instanceof IOException )
+        {
+            throw (IOException) ex;
+        }
+        throw new IOException( ex.getMessage() );
+    }
+
+    /**
+     * @return url of service
+     */
+    @Override
+    public String getEventLoggingExtraInfo()
+    {
+        return null;
+    }
+
+    /**
+     * @param remoteHttpCacheAttributes the remoteHttpCacheAttributes to set
+     */
+    public void setRemoteHttpCacheAttributes( RemoteHttpCacheAttributes remoteHttpCacheAttributes )
+    {
+        this.remoteHttpCacheAttributes = remoteHttpCacheAttributes;
+    }
+
+    /**
+     * @return the remoteHttpCacheAttributes
+     */
+    public RemoteHttpCacheAttributes getRemoteHttpCacheAttributes()
+    {
+        return remoteHttpCacheAttributes;
+    }
+}

Modified: commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCacheAttributes.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCacheAttributes.java?rev=1570993&r1=1570992&r2=1570993&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCacheAttributes.java (original)
+++ commons/proper/jcs/trunk/src/java/org/apache/commons/jcs/auxiliary/remote/http/client/RemoteHttpCacheAttributes.java Sun Feb 23 10:37:48 2014
@@ -1,228 +1,228 @@
-package org.apache.commons.jcs.auxiliary.remote.http.client;
-
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import org.apache.commons.jcs.auxiliary.remote.RemoteCacheAttributes;
-
-/** Http client specific settings. */
-public class RemoteHttpCacheAttributes
-    extends RemoteCacheAttributes
-{
-    /** Don't change. */
-    private static final long serialVersionUID = -5944327125140505212L;
-
-    /** http verison to use. */
-    private static final String DEFAULT_HTTP_VERSION = "1.1";
-
-    /** The max connections allowed per host */
-    private int maxConnectionsPerHost = 100;
-
-    /** The socket timeout. */
-    private int socketTimeoutMillis = 3000;
-
-    /** The socket connections timeout */
-    private int connectionTimeoutMillis = 5000;
-
-    /** http verison to use. */
-    private String httpVersion = DEFAULT_HTTP_VERSION;
-
-    /** The cache name will be included on the parameters */
-    private boolean includeCacheNameAsParameter = true;
-
-    /** keys and patterns will be included in the parameters */
-    private boolean includeKeysAndPatternsAsParameter = true;
-
-    /** keys and patterns will be included in the parameters */
-    private boolean includeRequestTypeasAsParameter = true;
-    
-    /** The complete URL to the service. */
-    private String url;
-    
-    /** The default classname for the client.  */
-    public static final String DEFAULT_REMOTE_HTTP_CLIENT_CLASS_NAME = RemoteHttpCacheClient.class.getName();
-    
-    /** This allows users to inject their own client implementation. */
-    private String remoteHttpClientClassName = DEFAULT_REMOTE_HTTP_CLIENT_CLASS_NAME;
-
-    /**
-     * @param maxConnectionsPerHost the maxConnectionsPerHost to set
-     */
-    public void setMaxConnectionsPerHost( int maxConnectionsPerHost )
-    {
-        this.maxConnectionsPerHost = maxConnectionsPerHost;
-    }
-
-    /**
-     * @return the maxConnectionsPerHost
-     */
-    public int getMaxConnectionsPerHost()
-    {
-        return maxConnectionsPerHost;
-    }
-
-    /**
-     * @param socketTimeoutMillis the socketTimeoutMillis to set
-     */
-    public void setSocketTimeoutMillis( int socketTimeoutMillis )
-    {
-        this.socketTimeoutMillis = socketTimeoutMillis;
-    }
-
-    /**
-     * @return the socketTimeoutMillis
-     */
-    public int getSocketTimeoutMillis()
-    {
-        return socketTimeoutMillis;
-    }
-
-    /**
-     * @param httpVersion the httpVersion to set
-     */
-    public void setHttpVersion( String httpVersion )
-    {
-        this.httpVersion = httpVersion;
-    }
-
-    /**
-     * @return the httpVersion
-     */
-    public String getHttpVersion()
-    {
-        return httpVersion;
-    }
-
-    /**
-     * @param connectionTimeoutMillis the connectionTimeoutMillis to set
-     */
-    public void setConnectionTimeoutMillis( int connectionTimeoutMillis )
-    {
-        this.connectionTimeoutMillis = connectionTimeoutMillis;
-    }
-
-    /**
-     * @return the connectionTimeoutMillis
-     */
-    public int getConnectionTimeoutMillis()
-    {
-        return connectionTimeoutMillis;
-    }
-
-    /**
-     * @param includeCacheNameInURL the includeCacheNameInURL to set
-     */
-    public void setIncludeCacheNameAsParameter( boolean includeCacheNameInURL )
-    {
-        this.includeCacheNameAsParameter = includeCacheNameInURL;
-    }
-
-    /**
-     * @return the includeCacheNameInURL
-     */
-    public boolean isIncludeCacheNameAsParameter()
-    {
-        return includeCacheNameAsParameter;
-    }
-
-    /**
-     * @param includeKeysAndPatternsInURL the includeKeysAndPatternsInURL to set
-     */
-    public void setIncludeKeysAndPatternsAsParameter( boolean includeKeysAndPatternsInURL )
-    {
-        this.includeKeysAndPatternsAsParameter = includeKeysAndPatternsInURL;
-    }
-
-    /**
-     * @return the includeKeysAndPatternsInURL
-     */
-    public boolean isIncludeKeysAndPatternsAsParameter()
-    {
-        return includeKeysAndPatternsAsParameter;
-    }
-
-    /**
-     * @param includeRequestTypeasAsParameter the includeRequestTypeasAsParameter to set
-     */
-    public void setIncludeRequestTypeasAsParameter( boolean includeRequestTypeasAsParameter )
-    {
-        this.includeRequestTypeasAsParameter = includeRequestTypeasAsParameter;
-    }
-
-    /**
-     * @return the includeRequestTypeasAsParameter
-     */
-    public boolean isIncludeRequestTypeasAsParameter()
-    {
-        return includeRequestTypeasAsParameter;
-    }
-
-    /**
-     * @param url the url to set
-     */
-    public void setUrl( String url )
-    {
-        this.url = url;
-    }
-
-    /**
-     * @return the url
-     */
-    public String getUrl()
-    {
-        return url;
-    }
-
-    /**
-     * @param remoteHttpClientClassName the remoteHttpClientClassName to set
-     */
-    public void setRemoteHttpClientClassName( String remoteHttpClientClassName )
-    {
-        this.remoteHttpClientClassName = remoteHttpClientClassName;
-    }
-
-    /**
-     * @return the remoteHttpClientClassName
-     */
-    public String getRemoteHttpClientClassName()
-    {
-        return remoteHttpClientClassName;
-    }
-
-    /**
-     * @return String details
-     */
-    @Override
-    public String toString()
-    {
-        StringBuffer buf = new StringBuffer();
-        buf.append( "\n RemoteHttpCacheAttributes" );
-        buf.append( "\n maxConnectionsPerHost = [" + getMaxConnectionsPerHost() + "]" );
-        buf.append( "\n socketTimeoutMillis = [" + getSocketTimeoutMillis() + "]" );
-        buf.append( "\n httpVersion = [" + getHttpVersion() + "]" );
-        buf.append( "\n connectionTimeoutMillis = [" + getConnectionTimeoutMillis() + "]" );
-        buf.append( "\n includeCacheNameAsParameter = [" + isIncludeCacheNameAsParameter() + "]" );
-        buf.append( "\n includeKeysAndPatternsAsParameter = [" + isIncludeKeysAndPatternsAsParameter() + "]" );
-        buf.append( "\n includeRequestTypeasAsParameter = [" + isIncludeRequestTypeasAsParameter() + "]" );
-        buf.append( "\n url = [" + getUrl() + "]" );
-        buf.append( "\n remoteHttpClientClassName = [" + getRemoteHttpClientClassName() + "]" );
-        buf.append( super.toString() );
-        return buf.toString();
-    }
-}
+package org.apache.commons.jcs.auxiliary.remote.http.client;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.apache.commons.jcs.auxiliary.remote.RemoteCacheAttributes;
+
+/** Http client specific settings. */
+public class RemoteHttpCacheAttributes
+    extends RemoteCacheAttributes
+{
+    /** Don't change. */
+    private static final long serialVersionUID = -5944327125140505212L;
+
+    /** http verison to use. */
+    private static final String DEFAULT_HTTP_VERSION = "1.1";
+
+    /** The max connections allowed per host */
+    private int maxConnectionsPerHost = 100;
+
+    /** The socket timeout. */
+    private int socketTimeoutMillis = 3000;
+
+    /** The socket connections timeout */
+    private int connectionTimeoutMillis = 5000;
+
+    /** http verison to use. */
+    private String httpVersion = DEFAULT_HTTP_VERSION;
+
+    /** The cache name will be included on the parameters */
+    private boolean includeCacheNameAsParameter = true;
+
+    /** keys and patterns will be included in the parameters */
+    private boolean includeKeysAndPatternsAsParameter = true;
+
+    /** keys and patterns will be included in the parameters */
+    private boolean includeRequestTypeasAsParameter = true;
+
+    /** The complete URL to the service. */
+    private String url;
+
+    /** The default classname for the client.  */
+    public static final String DEFAULT_REMOTE_HTTP_CLIENT_CLASS_NAME = RemoteHttpCacheClient.class.getName();
+
+    /** This allows users to inject their own client implementation. */
+    private String remoteHttpClientClassName = DEFAULT_REMOTE_HTTP_CLIENT_CLASS_NAME;
+
+    /**
+     * @param maxConnectionsPerHost the maxConnectionsPerHost to set
+     */
+    public void setMaxConnectionsPerHost( int maxConnectionsPerHost )
+    {
+        this.maxConnectionsPerHost = maxConnectionsPerHost;
+    }
+
+    /**
+     * @return the maxConnectionsPerHost
+     */
+    public int getMaxConnectionsPerHost()
+    {
+        return maxConnectionsPerHost;
+    }
+
+    /**
+     * @param socketTimeoutMillis the socketTimeoutMillis to set
+     */
+    public void setSocketTimeoutMillis( int socketTimeoutMillis )
+    {
+        this.socketTimeoutMillis = socketTimeoutMillis;
+    }
+
+    /**
+     * @return the socketTimeoutMillis
+     */
+    public int getSocketTimeoutMillis()
+    {
+        return socketTimeoutMillis;
+    }
+
+    /**
+     * @param httpVersion the httpVersion to set
+     */
+    public void setHttpVersion( String httpVersion )
+    {
+        this.httpVersion = httpVersion;
+    }
+
+    /**
+     * @return the httpVersion
+     */
+    public String getHttpVersion()
+    {
+        return httpVersion;
+    }
+
+    /**
+     * @param connectionTimeoutMillis the connectionTimeoutMillis to set
+     */
+    public void setConnectionTimeoutMillis( int connectionTimeoutMillis )
+    {
+        this.connectionTimeoutMillis = connectionTimeoutMillis;
+    }
+
+    /**
+     * @return the connectionTimeoutMillis
+     */
+    public int getConnectionTimeoutMillis()
+    {
+        return connectionTimeoutMillis;
+    }
+
+    /**
+     * @param includeCacheNameInURL the includeCacheNameInURL to set
+     */
+    public void setIncludeCacheNameAsParameter( boolean includeCacheNameInURL )
+    {
+        this.includeCacheNameAsParameter = includeCacheNameInURL;
+    }
+
+    /**
+     * @return the includeCacheNameInURL
+     */
+    public boolean isIncludeCacheNameAsParameter()
+    {
+        return includeCacheNameAsParameter;
+    }
+
+    /**
+     * @param includeKeysAndPatternsInURL the includeKeysAndPatternsInURL to set
+     */
+    public void setIncludeKeysAndPatternsAsParameter( boolean includeKeysAndPatternsInURL )
+    {
+        this.includeKeysAndPatternsAsParameter = includeKeysAndPatternsInURL;
+    }
+
+    /**
+     * @return the includeKeysAndPatternsInURL
+     */
+    public boolean isIncludeKeysAndPatternsAsParameter()
+    {
+        return includeKeysAndPatternsAsParameter;
+    }
+
+    /**
+     * @param includeRequestTypeasAsParameter the includeRequestTypeasAsParameter to set
+     */
+    public void setIncludeRequestTypeasAsParameter( boolean includeRequestTypeasAsParameter )
+    {
+        this.includeRequestTypeasAsParameter = includeRequestTypeasAsParameter;
+    }
+
+    /**
+     * @return the includeRequestTypeasAsParameter
+     */
+    public boolean isIncludeRequestTypeasAsParameter()
+    {
+        return includeRequestTypeasAsParameter;
+    }
+
+    /**
+     * @param url the url to set
+     */
+    public void setUrl( String url )
+    {
+        this.url = url;
+    }
+
+    /**
+     * @return the url
+     */
+    public String getUrl()
+    {
+        return url;
+    }
+
+    /**
+     * @param remoteHttpClientClassName the remoteHttpClientClassName to set
+     */
+    public void setRemoteHttpClientClassName( String remoteHttpClientClassName )
+    {
+        this.remoteHttpClientClassName = remoteHttpClientClassName;
+    }
+
+    /**
+     * @return the remoteHttpClientClassName
+     */
+    public String getRemoteHttpClientClassName()
+    {
+        return remoteHttpClientClassName;
+    }
+
+    /**
+     * @return String details
+     */
+    @Override
+    public String toString()
+    {
+        StringBuffer buf = new StringBuffer();
+        buf.append( "\n RemoteHttpCacheAttributes" );
+        buf.append( "\n maxConnectionsPerHost = [" + getMaxConnectionsPerHost() + "]" );
+        buf.append( "\n socketTimeoutMillis = [" + getSocketTimeoutMillis() + "]" );
+        buf.append( "\n httpVersion = [" + getHttpVersion() + "]" );
+        buf.append( "\n connectionTimeoutMillis = [" + getConnectionTimeoutMillis() + "]" );
+        buf.append( "\n includeCacheNameAsParameter = [" + isIncludeCacheNameAsParameter() + "]" );
+        buf.append( "\n includeKeysAndPatternsAsParameter = [" + isIncludeKeysAndPatternsAsParameter() + "]" );
+        buf.append( "\n includeRequestTypeasAsParameter = [" + isIncludeRequestTypeasAsParameter() + "]" );
+        buf.append( "\n url = [" + getUrl() + "]" );
+        buf.append( "\n remoteHttpClientClassName = [" + getRemoteHttpClientClassName() + "]" );
+        buf.append( super.toString() );
+        return buf.toString();
+    }
+}



Mime
View raw message