abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmsn...@apache.org
Subject svn commit: r438601 - /incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/impl/AbstractRequestHandler.java
Date Wed, 30 Aug 2006 19:45:57 GMT
Author: jmsnell
Date: Wed Aug 30 12:45:57 2006
New Revision: 438601

URL: http://svn.apache.org/viewvc?rev=438601&view=rev
Log:
Removing the cache stuff from AbstractRequestHandler. 
Will likely be refactoring caching in the near future

Modified:
    incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/impl/AbstractRequestHandler.java

Modified: incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/impl/AbstractRequestHandler.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/impl/AbstractRequestHandler.java?rev=438601&r1=438600&r2=438601&view=diff
==============================================================================
--- incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/impl/AbstractRequestHandler.java
(original)
+++ incubator/abdera/java/trunk/server/src/main/java/org/apache/abdera/server/impl/AbstractRequestHandler.java
Wed Aug 30 12:45:57 2006
@@ -21,8 +21,6 @@
 import org.apache.abdera.server.RequestHandler;
 import org.apache.abdera.server.ResponseContext;
 import org.apache.abdera.server.ServerConstants;
-import org.apache.abdera.server.cache.Cache;
-import org.apache.abdera.server.cache.CacheEntry;
 import org.apache.abdera.server.exceptions.AbderaServerException;
 import org.apache.abdera.server.util.ResourceType;
 
@@ -42,7 +40,6 @@
       checkMethod(requestContext);
       checkModified(requestContext);
       checkRequest(requestContext);
-      checkCache(requestContext,response,getCacheKey());
       response = internalInvoke(requestContext, response);
       if (response != null)
         return response;
@@ -61,31 +58,6 @@
   }
 
   protected abstract ResponseContext createResponseContext();
-  
-  /**
-   * Returns this handlers cache (if any)
-   */
-  protected abstract Cache getCache();
-  
-  /**
-   * Return a cache key for this request
-   */
-  protected abstract String getCacheKey();
-  
-  protected abstract boolean useCache();
-  
-  protected CacheEntry.CacheDisposition checkCache(
-    RequestContext requestContext,
-    ResponseContext responseContext, 
-    String cacheKey) {
-      if (useCache()) {
-        Cache cache = getCache();
-        if (cache != null) {
-          return cache.process(requestContext, responseContext, cacheKey);
-        }
-      } 
-      return CacheEntry.CacheDisposition.TRANSPARENT;
-  }
   
   /**
    * Returns the type of the requested resource



Mime
View raw message