Skip to main content
Skip table of contents

Configure Query Caching - SuperWEB2

Query caching is designed to give a performance boost to SuperWEB2 by caching query results.

This means that if the same table is created/tabulated more than once, the tabulation result can be obtained from the cache instead of using SuperSERVER to perform the tabulation.

Cache Options Available in SuperWEB2

SuperWEB2 supports three caching options:

Cache StrategyUse When...DescriptionConfiguration Instructions
CouchBaseMemoryPersistentCacheYou want the cache to survive between SuperWEB2 server restarts

This option provides a disk-based persistent cache as well as high performance memory caching once the cache is loaded. To use this option, you need to install Couchbase 1.8.0.

This cache strategy is implemented as 2-level caching: once the cache is loaded from the Couchbase server into the Java Virtual Machine (JVM) running SuperWEB2, it will be cached into the LRU map for even faster results without the extra network overheads of making a request to the Couchbase server.

In Couchbase server, multiple Memcached Buckets can be defined with an administrator specified quota. If this quota is exhausted, a Memcached Bucket will discard expired or least recently used data to make room for new data.

For more information about how Memcached works in Couchbase server, see: http://www.couchbase.com/memcached 

Configure CouchBaseMemoryPersistentCache

LRUMemoryCache

(Least Recently Used Memory Cache)

You want to cache results but do not need the cache to persist between restarts

This is a light-version memory cache making use of the Java Virtual Machine (JVM) heap memory available in the same container as the SuperWEB2.

This option uses a key-value map data structure with a configurable size to cache query results. When the map is full and a new table result needs to be cached, the least-recently-used cached object is removed and replaced by the new object.

All cached objects are lost if the Tomcat server is restarted.

Configure LRUMemoryCache
NoCacheYou do not want to cache any resultsThis is the default option that comes with SuperWEB2. No results are cached.
 

Clean Up/Refresh the Cache Results

 In some cases you may want to update the cache with the latest query result. For example, you might have made some configuration changes to SuperWEB2 or the SXV4 data might have changed.

The steps to refresh the cache depend on the type of caching:

Cache StrategySteps
CouchBaseMemoryPersistentCache

The recommended practice for clearing a Couchbase Bucket via the Administrator GUI is to delete and recreate the bucket:

  1. Stop the Tomcat server. This will clear all data cached in JVM memory.
  2. Login to the Couchbase dashboard at: http://localhost:8091/index.html
  3. Select Data Buckets and click Edit.


    The Configure Bucket window displays.Click Flush.
  4. Start the Tomcat server running SuperWEB2.
LRUMemoryCacheStop and restart Tomcat. This will clear all data cached in JVM memory.

 

 

 

 

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.