You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: documentation/en/user/source/configuration/storage.rst
-218Lines changed: 0 additions & 218 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -255,9 +255,6 @@ a thorough assessment of costs associated to seeding and serving caches**. Yet w
255
255
the bigger the size difference between two identical caches on S3 vs a regular file system. The S3 cache takes less space because the actual space used for each
256
256
tile is not padded to a file system block size. For example, the ``topp:states`` layer seeded up to zoom level 10 for EPSG:4326 with png8 format takes roughly
257
257
240MB on an Ext4 file system, and about 21MB on S3.
258
-
* Use in-memory caching. When serving S3 tiles from GeoWebcache, you can greately reduce the number of GET requests to S3 by configuring an in-memory cache as
259
-
described in the "In-Memory caching" section bellow. This will allow for frequently requested tiles to be kept in memory instead of retrieved from S3 on each
260
-
call.
261
258
262
259
The following is an example OpenLayers 3 HTML/JavaScript to set up a map that fetches tiles from a pre-seeded geowebcache layer directly from S3. We're using the typical
263
260
GeoServer ``topp:states`` sample layer on a fictitious ``my-geowebcache-bucket`` bucket, using ``test-cache`` as the cache prefix, png8 tile format, and EPSG:4326 CRS.
@@ -636,221 +633,6 @@ The *layer* parameter identifies the layer whose associated blob store content s
636
633
637
634
This are the only valid combinations of this parameters other combinations will ignore some of the provided parameters or will throw an exception.
638
635
639
-
In-Memory caching
640
-
-----------------
641
-
642
-
Default **blobstore** can be changed with a new one called **MemoryBlobStore**, which allows in memory tile caching. The **MemoryBlobStore** is a wrapper of a **blobstore**
643
-
implementation, which can be the default one(*FileBlobStore*) or another one. For using the new **blobstore** implementation, the user have to
644
-
modify the **blobstore** bean associated to the **gwcStorageBroker** bean (inside the Application Context file *geowebcache-core-context.xml*) by setting *gwcMemoryBlobStore*
645
-
instead of *gwcBlobStore*.
646
-
647
-
The configuration of a MemoryBlobStore requires a *blobstore* to wrap and a **CacheProvider** object. This one provides the caching mechanism for saving input data in memory.
648
-
User can define different caching objects but can only inject one of them inside the **MemoryBlobStore**. More information about the **CacheProvider** can be found in the next section.
649
-
650
-
An example of MemoryBlobStore configuration can be found beow:
.. note:: Note that *cacheProviderName*/*cacheProvider* cannote be used together, if a *cacheProvider* is defined, the *cacheProviderName* is not considered. If *cacheProviderName*/*cacheProvider* are not defined, the **MemoryBlobStore** will internally search for a suitable **CacheProvider**.
663
-
664
-
CacheProvider configuration
665
-
+++++++++++++++++++++++++++
666
-
667
-
A **CacheProvider** object should be configured with an input object called **CacheConfiguration**. **CacheConfiguration** parameters are:
668
-
669
-
* *hardMemoryLimit* : which is the cache size in Mb
670
-
* *policy* : which can be LRU, LFU, EXPIRE_AFTER_WRITE, EXPIRE_AFTER_ACCESS, NULL
671
-
* *evitionTime* : which is the cache eviction time in seconds
672
-
* *concurrencyLevel* : which is the cache concurrency level
673
-
674
-
These parameters must be defined as properties in the **cacheConfiguration** bean in the Spring Application Context (like *geowebcache-core-context.xml*).
675
-
676
-
At the time of writing there are two implementations of the **CacheProvider** interface:
677
-
678
-
* **GuavaCacheProvider**
679
-
* **HazelcastCacheProvider**
680
-
681
-
GuavaCacheProvider
682
-
``````````````````````
683
-
**GuavaCacheProvider** provides local in-memory caching by using a `Guava <https://code.google.com/p/guava-libraries/wiki/CachesExplained>`_ *Cache* for storing the various GWC Tiles locally on the machine. For configuring a **GuavaCacheProvider**
684
-
the user must create a new bean in the Application Context file (like *geowebcache-core-context.xml*) and then add a reference to a **CacheConfiguration** instance.
<propertyname="policy"value="EXPIRE_AFTER_ACCESS"/> <!-- Cache Eviction Policy is EXPIRE_AFTER_ACCESS. Other values are EXPIRE_AFTER_WRITE, NULL(LRU eviction based on cache size) -->
693
-
<propertyname="evitionTime"value="240"/> <!-- Eviction time is 240 seconds -->
694
-
<propertyname="concurrencyLevel"value="4"/> <!-- Concurrency Level of the cache is 4 -->
<propertyname="configuration"ref="cacheConfiguration"/> <!-- Setting of the configuration -->
699
-
</bean>
700
-
701
-
702
-
HazelcastCacheProvider
703
-
``````````````````````
704
-
**HazelcastCacheProvider** is useful for implementing distributed in memory caching for clustering. It internally uses `Hazelcast <http://docs.hazelcast.org/docs/3.3/manual/html/>`_ for handling distributed caching.
705
-
The **HazelcastCacheProvider** configuration requires another object called **HazelcastLoader**. This object accepts an Hazelcast instance or loads a file called *hazelcast.xml* from a proper directory defined
706
-
by the property "hazelcast.config.dir". If none of them is present, the CacheProvider object cannot be used.
707
-
708
-
The user must follow these rules for configuring the Hazelcast instance:
709
-
710
-
#. The Hazelcast configuration requires a Map object with name *CacheProviderMap*
711
-
#. Map eviction policy must be *LRU* or *LFU*
712
-
#. Map configuration must have a fixed size defined in Mb
713
-
#. Map configuration must have **USED_HEAP_SIZE** as *MaxSizePolicy*
In this section are described other available configuration parameters to configure:
805
-
806
-
* Cache expiration time:
807
-
808
-
.. code-block:: xml
809
-
810
-
<mapname="CacheProviderMap">
811
-
...
812
-
813
-
<time-to-live-seconds>0</time-to-live-seconds>
814
-
<max-idle-seconds>0</max-idle-seconds>
815
-
816
-
</map>
817
-
818
-
Where *time-to-live-seconds* indicates how many seconds an entry can stay in cache and *max-idle-seconds* indicates how many seconds an entry may be not accessed before being evicted.
819
-
820
-
* Near Cache.
821
-
822
-
.. code-block:: xml
823
-
824
-
<mapname="CacheProviderMap">
825
-
...
826
-
<near-cache>
827
-
<!--
828
-
Same configuration parameters of the Hazelcast Map. Note that size indicates the maximum number of
829
-
entries in the near cache. A value of Integer.MAX_VALUE indicates no limit on the maximum
830
-
size.
831
-
-->
832
-
<max-size>5000</max-size>
833
-
<time-to-live-seconds>0</time-to-live-seconds>
834
-
<max-idle-seconds>60</max-idle-seconds>
835
-
<eviction-policy>LRU</eviction-policy>
836
-
837
-
<!--
838
-
Indicates if a cached entry can be evicted if the same value is modified in the Hazelcast Map. Default is true.
839
-
-->
840
-
<invalidate-on-change>true</invalidate-on-change>
841
-
842
-
<!--
843
-
Indicates if local entries must be cached. Default is false.
844
-
-->
845
-
<cache-local-entries>false</cache-local-entries>
846
-
</near-cache>
847
-
848
-
</map>
849
-
850
-
Near Cache is a local cache for each cluster instance which is used for caching entries in the other cluster instances. This behaviour avoids to request those entries each time by executing a remote call. This feature could be helpful in order to improve Hazelcast Cache performances.
851
-
852
-
.. note:: A value of *max-size* bigger or equal to Integer.MAX_VALUE cannot be used in order to avoid an uncontrollable growth of the cache size.
Copy file name to clipboardExpand all lines: documentation/en/user/source/webinterface/status.rst
-5Lines changed: 0 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,8 +30,3 @@ Runtime statistics
30
30
31
31
The Status page displays basic runtime statistics including: uptime; how many requests have been made; total and peak throughput and statitics over intervals of 3, 15, and 60 seconds.
32
32
33
-
In Memory Cache statistics
34
-
--------------------------
35
-
36
-
If the **blobstore** object used is an instance of **MemoryBlobStore**, the user can find a new section called *In Memory Cache statistics*, containing the statistics of the cache used
37
-
by the **blobstore**. Note that these statistics are related to the local entries, even in case of distributed in-memory caching.
0 commit comments