Terracotta Ehcache 10.2 | Ehcache API Developer Guide | Clustered Caches | Starting the Terracotta Server
 
Starting the Terracotta Server
Information on how to start the Terracotta Server is contained in the Terracotta Server Administration Guide. See the section Starting and Stopping the Terracotta Server for details.
You can start the Terracotta Server with the following configuration. It contains the bare minimum configuration required for the samples in the rest of the document to work.
<?xml version="1.0" encoding="UTF-8"?>
<tc-config xmlns="http://www.terracotta.org/config"
xmlns:ohr="http://www.terracotta.org/config/offheap-resource">

<services>
<service id="resources">
<ohr:offheap-resources>
<ohr:resource name="primary-server-resource"
unit="MB">128</ohr:resource> <!-- 1 -->
<ohr:resource name="secondary-server-resource"
unit="MB">96</ohr:resource> <!-- 2 -->
</ohr:offheap-resources>
</service>
</services>
</tc-config>
The above configuration defines two named server off-heap resources:
1
An off-heap resource of 128 MB size named "primary-server-resource".
2
Another off-heap resource named "secondary-server-resource" with 96 MB capacity.
The rest of the document explains in detail how you can configure cache managers and caches to consume the server's off-heap resources.

Copyright © 2010-2019 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Innovation Release