Author: ruwan
Date: Tue Dec 11 21:31:50 2007
New Revision: 603466

URL: http://svn.apache.org/viewvc?rev=603466&view=rev
Log:
changed the cache mediator according to the cahnges in the wso2-caching

Modified:
    
webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/mediators/builtin/CacheMediator.java
    webservices/synapse/trunk/java/pom.xml

Modified: 
webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/mediators/builtin/CacheMediator.java
URL: 
http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/mediators/builtin/CacheMediator.java?rev=603466&r1=603465&r2=603466&view=diff
==============================================================================
--- 
webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/mediators/builtin/CacheMediator.java
 (original)
+++ 
webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/mediators/builtin/CacheMediator.java
 Tue Dec 11 21:31:50 2007
@@ -180,7 +180,7 @@
             handleException("Response messages cannot be handled in a non 
collector cache", synCtx);
         }
 
-        String requestHash = (String) 
synCtx.getProperty(CachingConstants.REQUEST_HASH_KEY);
+        String requestHash = (String) 
synCtx.getProperty(CachingConstants.REQUEST_HASH);
 
         if (requestHash != null) {
             if (traceOrDebugOn) {
@@ -251,8 +251,9 @@
 
         String requestHash = null;
         try {  
-            requestHash = digestGenerator.getDigest(((Axis2MessageContext) 
synCtx).getAxis2MessageContext());
-            synCtx.setProperty(CachingConstants.REQUEST_HASH_KEY, requestHash);
+            requestHash = digestGenerator.getDigest(
+                ((Axis2MessageContext) synCtx).getAxis2MessageContext());
+            synCtx.setProperty(CachingConstants.REQUEST_HASH, requestHash);
         } catch (CachingException e) {
             handleException("Error in calculating the hash value of the 
request", e, synCtx);
         }
@@ -288,14 +289,14 @@
 
                     synCtx.setEnvelope(omSOAPEnv);
                 } catch (AxisFault axisFault) {
-                    handleException("Error setting response envelope from 
cache : " + cacheManagerKey,
-                        synCtx);
+                    handleException("Error setting response envelope from 
cache : "
+                        + cacheManagerKey, synCtx);
                 } catch (IOException ioe) {
-                    handleException("Error setting response envelope from 
cache : " + cacheManagerKey,
-                        ioe, synCtx);
+                    handleException("Error setting response envelope from 
cache : "
+                        + cacheManagerKey, ioe, synCtx);
                 } catch (SOAPException soape) {
-                    handleException("Error setting response envelope from 
cache : " + cacheManagerKey,
-                        soape, synCtx);
+                    handleException("Error setting response envelope from 
cache : "
+                        + cacheManagerKey, soape, synCtx);
                 }
 
                 // take specified action on cache hit
@@ -342,7 +343,6 @@
 
         } else {
 
-            // todo: find a proper way of achieving the cache size check
             // if not found in cache, check if we can cache this request
             if (cacheManager.getCacheKeys().size() == inMemoryCacheSize) {
                 cacheManager.removeExpiredResponses(cfgCtx);

Modified: webservices/synapse/trunk/java/pom.xml
URL: 
http://svn.apache.org/viewvc/webservices/synapse/trunk/java/pom.xml?rev=603466&r1=603465&r2=603466&view=diff
==============================================================================
--- webservices/synapse/trunk/java/pom.xml (original)
+++ webservices/synapse/trunk/java/pom.xml Tue Dec 11 21:31:50 2007
@@ -887,6 +887,10 @@
                     <artifactId>axis2-kernel</artifactId>
                 </exclusion>
                 <exclusion>
+                    <groupId>org.apache.axis2</groupId>
+                    <artifactId>axis2-saaj</artifactId>
+                </exclusion>
+                <exclusion>
                     <groupId>org.apache.ws.commons.axiom</groupId>
                     <artifactId>axiom-impl</artifactId>
                 </exclusion>



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to