jspwiki-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From juanpa...@apache.org
Subject svn commit: r1588836 - in /jspwiki/trunk: ./ jspwiki-war/src/main/java/org/apache/wiki/ jspwiki-war/src/main/java/org/apache/wiki/attachment/ jspwiki-war/src/main/java/org/apache/wiki/providers/ jspwiki-war/src/main/java/org/apache/wiki/render/ jspwiki...
Date Sun, 20 Apr 2014 21:29:03 GMT
Author: juanpablo
Date: Sun Apr 20 21:29:02 2014
New Revision: 1588836

URL: http://svn.apache.org/r1588836
Log:
 * 2.10.1-svn-14
       
 * Fixed JSPWIKI-832 - [Portable] Problems setting up multiple wikis using a shared JSPWiki
libraries 
   (patch by Siegfried Goeschl - thanks!)

Modified:
    jspwiki/trunk/ChangeLog
    jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/Release.java
    jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/attachment/AttachmentManager.java
    jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingAttachmentProvider.java
    jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingProvider.java
    jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/render/RenderingManager.java
    jspwiki/trunk/jspwiki-war/src/main/resources/ehcache.xml

Modified: jspwiki/trunk/ChangeLog
URL: http://svn.apache.org/viewvc/jspwiki/trunk/ChangeLog?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/ChangeLog (original)
+++ jspwiki/trunk/ChangeLog Sun Apr 20 21:29:02 2014
@@ -1,3 +1,10 @@
+2014-04-20  Juan Pablo Santos (juanpablo AT apache DOT org)
+
+       * 2.10.1-svn-14
+       
+       * Fixed JSPWIKI-832 - [Portable] Problems setting up multiple wikis using a shared
JSPWiki libraries 
+         (patch by Siegfried Goeschl - thanks!)
+
 2014-04-01  Harry Metske (metskem@apache.org)
 
        * 2.10.1-svn-13

Modified: jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/Release.java
URL: http://svn.apache.org/viewvc/jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/Release.java?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/Release.java (original)
+++ jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/Release.java Sun Apr 20 21:29:02
2014
@@ -72,7 +72,7 @@ public final class Release {
      *  <p>
      *  If the build identifier is empty, it is not added.
      */
-    public static final String     BUILD         = "13";
+    public static final String     BUILD         = "14";
     
     /**
      *  This is the generic version string you should use when printing out the version.
 It is of 

Modified: jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/attachment/AttachmentManager.java
URL: http://svn.apache.org/viewvc/jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/attachment/AttachmentManager.java?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/attachment/AttachmentManager.java
(original)
+++ jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/attachment/AttachmentManager.java
Sun Apr 20 21:29:02 2014
@@ -137,12 +137,13 @@ public class AttachmentManager
         //
         //  Create and initialize the provider.
         //
+        String cacheName = engine.getApplicationName() + "." + CACHE_NAME;
         try {
-            if (m_cacheManager.cacheExists(CACHE_NAME)) {
-                m_dynamicAttachments = m_cacheManager.getCache(CACHE_NAME);
+            if (m_cacheManager.cacheExists(cacheName)) {
+                m_dynamicAttachments = m_cacheManager.getCache(cacheName);
             } else {
-                log.info("cache with name " + CACHE_NAME + " not found in ehcache.xml, creating
it with defaults.");
-                m_dynamicAttachments = new Cache(CACHE_NAME, DEFAULT_CACHECAPACITY, false,
false, 0, 0);
+                log.info("cache with name " + cacheName + " not found in ehcache.xml, creating
it with defaults.");
+                m_dynamicAttachments = new Cache(cacheName, DEFAULT_CACHECAPACITY, false,
false, 0, 0);
                 m_cacheManager.addCache(m_dynamicAttachments);
             }
 

Modified: jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingAttachmentProvider.java
URL: http://svn.apache.org/viewvc/jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingAttachmentProvider.java?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingAttachmentProvider.java
(original)
+++ jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingAttachmentProvider.java
Sun Apr 20 21:29:02 2014
@@ -94,23 +94,24 @@ public class CachingAttachmentProvider
     {
         log.info("Initing CachingAttachmentProvider");
 
-        if (m_cacheManager.cacheExists(ATTCOLLCACHE_NAME)) {
-            m_cache = m_cacheManager.getCache(ATTCOLLCACHE_NAME);
+        String attCollCacheName = engine.getApplicationName() + "." + ATTCOLLCACHE_NAME;
+        if (m_cacheManager.cacheExists(attCollCacheName)) {
+            m_cache = m_cacheManager.getCache(attCollCacheName);
         } else {
-            m_cache = new Cache(ATTCOLLCACHE_NAME, m_capacity, false, false, 0, 0);
+            m_cache = new Cache(attCollCacheName, m_capacity, false, false, 0, 0);
             m_cacheManager.addCache(m_cache);
         }
 
         //
         // cache for the individual Attachment objects, attachment name is key, the Attachment
object is the cached object
         //
-        if (m_cacheManager.cacheExists(ATTCACHE_NAME)) {
-            m_attCache = m_cacheManager.getCache(ATTCACHE_NAME);
+        String attCacheName = engine.getApplicationName() + "." + ATTCACHE_NAME;
+        if (m_cacheManager.cacheExists(attCacheName)) {
+            m_attCache = m_cacheManager.getCache(attCacheName);
         } else {
-            m_attCache = new Cache(ATTCACHE_NAME, m_capacity, false, false, 0, 0);
+            m_attCache = new Cache(attCacheName, m_capacity, false, false, 0, 0);
             m_cacheManager.addCache(m_attCache);
         }
-
         //
         //  Find and initialize real provider.
         //

Modified: jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingProvider.java
URL: http://svn.apache.org/viewvc/jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingProvider.java?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingProvider.java
(original)
+++ jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/providers/CachingProvider.java
Sun Apr 20 21:29:02 2014
@@ -100,27 +100,30 @@ public class CachingProvider implements 
         // engine is used for getting the search engine
         m_engine = engine;
 
-        if (m_cacheManager.cacheExists(CACHE_NAME)) {
-            m_cache = m_cacheManager.getCache(CACHE_NAME);
+        String cacheName = engine.getApplicationName() + "." + CACHE_NAME;
+        if (m_cacheManager.cacheExists(cacheName)) {
+            m_cache = m_cacheManager.getCache(cacheName);
         } else {
-            log.info("cache with name " + CACHE_NAME +  " not found in ehcache.xml, creating
it with defaults.");
-            m_cache = new Cache(CACHE_NAME, DEFAULT_CACHECAPACITY, false, false, 0, 0);
+            log.info("cache with name " + cacheName +  " not found in ehcache.xml, creating
it with defaults.");
+            m_cache = new Cache(cacheName, DEFAULT_CACHECAPACITY, false, false, 0, 0);
             m_cacheManager.addCache(m_cache);
         }
 
-        if (m_cacheManager.cacheExists(TEXTCACHE_NAME)) {
-            m_textCache= m_cacheManager.getCache(TEXTCACHE_NAME);
+        String textCacheName = engine.getApplicationName() + "." + TEXTCACHE_NAME;
+        if (m_cacheManager.cacheExists(textCacheName)) {
+            m_textCache= m_cacheManager.getCache(textCacheName);
         } else {
-            log.info("cache with name " + TEXTCACHE_NAME +  " not found in ehcache.xml, creating
it with defaults.");
-            m_textCache = new Cache(TEXTCACHE_NAME, DEFAULT_CACHECAPACITY, false, false,
0, 0);
+            log.info("cache with name " + textCacheName +  " not found in ehcache.xml, creating
it with defaults.");
+            m_textCache = new Cache(textCacheName, DEFAULT_CACHECAPACITY, false, false, 0,
0);
             m_cacheManager.addCache(m_textCache);
         }
 
-        if (m_cacheManager.cacheExists(HISTORYCACHE_NAME)) {
-            m_historyCache= m_cacheManager.getCache(HISTORYCACHE_NAME);
+        String historyCacheName = engine.getApplicationName() + "." + HISTORYCACHE_NAME;
+        if (m_cacheManager.cacheExists(historyCacheName)) {
+            m_historyCache= m_cacheManager.getCache(historyCacheName);
         } else {
-            log.info("cache with name " + HISTORYCACHE_NAME +  " not found in ehcache.xml,
creating it with defaults.");
-            m_historyCache = new Cache(HISTORYCACHE_NAME, DEFAULT_CACHECAPACITY, false, false,
0, 0);
+            log.info("cache with name " + historyCacheName +  " not found in ehcache.xml,
creating it with defaults.");
+            m_historyCache = new Cache(historyCacheName, DEFAULT_CACHECAPACITY, false, false,
0, 0);
             m_cacheManager.addCache(m_historyCache);
         }
 

Modified: jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/render/RenderingManager.java
URL: http://svn.apache.org/viewvc/jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/render/RenderingManager.java?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/render/RenderingManager.java (original)
+++ jspwiki/trunk/jspwiki-war/src/main/java/org/apache/wiki/render/RenderingManager.java Sun
Apr 20 21:29:02 2014
@@ -107,11 +107,13 @@ public class RenderingManager implements
     {
         m_engine = engine;
 
-        if (m_cacheManager.cacheExists(DOCUMENTCACHE_NAME)) {
-            m_documentCache = m_cacheManager.getCache(DOCUMENTCACHE_NAME);
+        String documentCacheName = engine.getApplicationName() + "." + DOCUMENTCACHE_NAME;
+
+        if (m_cacheManager.cacheExists(documentCacheName)) {
+            m_documentCache = m_cacheManager.getCache(documentCacheName);
         } else {
-            log.info("cache with name " + DOCUMENTCACHE_NAME +  " not found in ehcache.xml,
creating it with defaults.");
-            m_documentCache = new Cache(DOCUMENTCACHE_NAME, DEFAULT_CACHESIZE, false, false,
m_cacheExpiryPeriod, m_cacheExpiryPeriod);
+            log.info("cache with name " + documentCacheName +  " not found in ehcache.xml,
creating it with defaults.");
+            m_documentCache = new Cache(documentCacheName, DEFAULT_CACHESIZE, false, false,
m_cacheExpiryPeriod, m_cacheExpiryPeriod);
             m_cacheManager.addCache(m_documentCache);
         }
 

Modified: jspwiki/trunk/jspwiki-war/src/main/resources/ehcache.xml
URL: http://svn.apache.org/viewvc/jspwiki/trunk/jspwiki-war/src/main/resources/ehcache.xml?rev=1588836&r1=1588835&r2=1588836&view=diff
==============================================================================
--- jspwiki/trunk/jspwiki-war/src/main/resources/ehcache.xml (original)
+++ jspwiki/trunk/jspwiki-war/src/main/resources/ehcache.xml Sun Apr 20 21:29:02 2014
@@ -59,19 +59,19 @@
                                      (specified as LFU)
     -->
     <!-- the default JSPWiki caches -->
-    <cache name="jspwiki.renderingCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.renderingCache" maxElementsInMemory="1000" />
 
-    <cache name="jspwiki.pageCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.pageCache" maxElementsInMemory="1000" />
 
-    <cache name="jspwiki.pageTextCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.pageTextCache" maxElementsInMemory="1000" />
 
-    <cache name="jspwiki.pageHistoryCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.pageHistoryCache" maxElementsInMemory="1000" />
 
-    <cache name="jspwiki.attachmentsCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.attachmentsCache" maxElementsInMemory="1000" />
 
-    <cache name="jspwiki.attachmentCollectionsCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.attachmentCollectionsCache" maxElementsInMemory="1000"
/>
 
-    <cache name="jspwiki.dynamicAttachmentCache" maxElementsInMemory="1000" />
+    <cache name="JSPWiki.jspwiki.dynamicAttachmentCache" maxElementsInMemory="1000" />
 
-    <cache name="jspwiki.rssCache" maxElementsInMemory="250" />
+    <cache name="JSPWiki.jspwiki.rssCache" maxElementsInMemory="250" />
 </ehcache>



Mime
View raw message