XML Schema for configuring Cacheonix 2.0.
The root element. Allows the definition of either a distributed or a local Cacheonix configurations.
CacheonixConfiguration defines the root element of the Cacheonix configuration file.
Logging configuration for Cacheonix. If logging is not configured, the logging level is set to WARN.
Defines a directory used by Cacheonix store various temporary files.
Type for representing a Cacheonix cluster node.
Default lock timeout in milliseconds. Cacheonix uses the default lock timeout for locks that were
acquired without setting the timeout explicitly. This value can be overridden from the command line by
setting the system property 'cacheonix.default.lock.timeout'.
Default unlock timeout in milliseconds.
The time between issuing a request to shutdown the server gracefully and time a forced shutdown is
performed. Partition contributors use this timeout to move their to other nodes to try to avoid loss
of data or recovery overhead that may result from the forced shutdown.
Default lease time. Cacheonix uses the default lease time for lease configurations that don't define
lease time. This value can be overridden from the command line by setting the system property
'cacheonix.default.lease.time'.
Time the selector should block for while waiting for a channel to become ready, must be greater than
zero. Majority of Cacheonix configuration should leave 'selectorTimeout' default.
SO_TIMEOUT
The cluster name. The cluster name limits cluster membership and communication to the cluster having
this name. The default is "Cacheonix".
Timeout after that a Cacheonix node considers that there is no communication path to other nodes and
proceeds to form a single-node cluster. homeAloneTimeout should be set to a value that is at least three
times higher than the clusterSurveyTimeout. The default value is 1 second. Use system property
'cacheonix.home.alone.timeout' to override the attribute 'homeAloneTimeout' from the command line.
Time interval that defines how often Cacheonix cluster announces itself using multicast.
Use system property 'cacheonix.cluster.announcement.timeout' to override clusterAnnouncementTimeout
from the command line. The default value for clusterAnnouncementTimeout is 100 milliseconds (0.1 seconds).
Time that a new Cacheonix node waits to identify all available Cacheonix clusters before starting a join
procedure. The cluster survey timeout should be set to a value that is at least four times higher than
the clusterAnnouncementTimeout. Use system property 'cacheonix.cluster.survey.timeout' to override
the clusterSurveyTimeout from the command line. The default value for clusterSurveyTimeout
is 0.5 seconds.
Worst-case communication latency. Cacheonix considers a host failed if it has not responded to
a connection request or to an I/O request within this time. Worst case network latency should take
in account time for that the host may be completely unresponsive due to garbage collection (GC).
Default is 10 seconds.
A local cache definition. Unlike a distributed cache, a local cache is limited to a single JVM.
A local cache. Unlike a distributed cache, a local cache is limited to a single JVM.
Type representing a communication facility used to broadcast messages to members of a Cacheonix cluster.
Type representing a node of a distributed partitioned cache.
A cache store that holds elements of the partitioned cache. Defining the cache store configures the
partitioned cache to operate as a partition contributor. The partitioned cache is not a partition
contributor if the store configuration is not provided. In this case the cache member remains a member
of the cluster but operates in a client-only mode. The total size of the partitioned cache is
determined as a multiple of the partition size and the number of cluster members that are partition
contributors.
A unique cache name.
A flag indicating if this cache configuration is a template configuration. The template cache
configuration is used to create a cache using method
Cacheonix.createCache(templateName, cacheName)
.
To mark a cache configuration as a template set this attribute to "true".
Note: The template cache configuration cannot be started.
Cacheonix reserves cache name "default" for a template cache configuration that is used to create
a new cache if automatic cache creation is enabled.
A cache name. The cache name should be unique throughout the Cacheonix configuration.
A flag indicating if this cache configuration is a template configuration. The template cache
configuration is used to create a cache using method
Cacheonix.createCache(templateName, cacheName)
.
To mark a cache configuration as a template set this attribute to "true".
Note: The template cache configuration cannot be started.
Cacheonix reserves cache name 'default' for a template cache configuration that is used to create
a new cache, if automatic cache creation is enabled. The default template configuration ignores
the 'template' attribute. It is always a template.
Type for representing IP addresses. This type restricts each field of the IP address to have a value between
zero and 255, i.e., [0-255].[0-255].[0-255].[0-255]. Examples: 192.168.123.1, 225.0.1.2.
Mandatory TCP port. Cacheonix uses the TCP port to listen on for network requests. Default is 8777.
Optional IP address used to limit the address Cacheonix node is listening. The address must be set to one
of the local interface addresses. If the address is not specified, the node will accept connections on
any of the node's IP addresses. This attribute may be useful for cluster nodes with multiple interfaces
where the node should accept connections only on a single interface. Do not set this attribute unless
there is a reason for limiting addresses that Cacheonix should listen on.
Mandatory address of the multicast group used for broadcast-style communication in the cluster. Cacheonix
uses multicast address send and receive messages to maintains cluster membership and inter-cache
communications. All Cacheonix instances that belong to the same cluster should use the same multicast
address. IP v.4 defines multicast addresses as addresses from 224.0.0.0 to 239.255.255.255. Addresses in
the range 224.0.0.0 to 224.0.0.255 are reserved for low-level multicast support operations. We recommend
using the range 239.000.000.000-239.255.255.255 for setting multicastAddress. Example:
multicastAddress="239.0.10.1".
A multicast port. A mandatory attribute multicastPort defines a UDP port that Cacheonix should use to
receive and to send multicast messages. All Cacheonix instances that belong to the same cluster should
use the same multicast port. We recommend setting multicast port to 9999. Example: multicastPort="9999".
Multicast TTL defines multicast TTL that is used to control how far the multicast messages
can propagate.
A value of zero indicates that a message should not be forwarded out of the current host. This value should be
used in development mode to avoid unintentional communications with cluster nodes running on other developer's
machines.
A value of one means that the message is not forwarded out of the current subnet. This value is suitable for QA
and for most production environments.
Values of two or greater mean larger, scopes as shown in the table below:
Multicast TTL |
Scope |
0 |
Node-local |
1 |
Link-local |
Lesser than 32 |
Site-local |
Lesser than 64 |
Region-local |
Lesser than 128 |
Continent-local |
Lesser than 255 |
Global |
Type for representing a data store that holds elements of a cache.
Type for representing a data store that holds elements of a local cache.
Type for representing a data store that holds elements of a distributed partitioned cache.
Type for representing time intervals. This type restricts each field of the TimeInterval type to have a
value consisting of numerical value and a unit measure. Examples: '5millis', '10s'.
Type for representing cache expiration time.
The time since the element was put into the cache before an element is discarded from the cache. An
element won't expire if the time to live is set to '0'. The default value is '0s' ('don't expire').
Example: timeToLive="2min".
The number of seconds since the last access before an element is discarded from the cache. The default
value is '0s' ('don't discard'). Example: idleTime="30seconds".
Defines replication configuration for a distributed cache.
The number of backup copies to be made for each element of a cache.
Lease time. If this attribute is not provided, Cacheonix uses value of the attribute
'defaultLeaseTime' defined in <server>.
Defines the Least Recently Used policy for managing cache size. When the cache becomes full, the least
recently used item is evicted from the cache.
The mandatory size of the cache in bytes. If the size of the elements of elements in cache exceeds
maxBytes, Cacheonix will evict the least recently used elements. Example: maxBytes="5mb".
Important: Cacheonix recommends setting 'maxBytes' so that total summa of sizes of all caches
doesn't exceed 40% of JVM heap.
The size of the cache in number of elements. If the number of elements in cache exceeds maxElements,
Cacheonix will evict the least recently used elements. Cacheonix does not limit the number of elements
in cache if the maximum number of elements is not set or if it is set to zero. Example: maxElements="5000".
Defines the fixed-size policy for managing cache size. When the cache becomes full, the cache will throw
a runtime exception in response to requests to add more elements. Use the fixed size policy to configure
Cacheonix to run in the loss-less data grid mode.
The mandatory size of the cache in bytes. In case of the fixed cache size, Cacheonix will return a error
to a request to add an element to the cache if the size of the elements of elements in cache exceeds
maxBytes. Example: maxBytes="5mb".
Important: Cacheonix recommends setting 'maxBytes' so that total summa of sizes of all caches
doesn't exceed 40% of JVM heap.
Defines a size in bytes. Cacheonix supports bytes, kilobytes (k, kb), megabytes (mb) and gigabytes (gb) as
a unit of measure. Example: maxBytes="5mb".
Provides a configuration for the notifier about element updates.
Defines the concurrency of sending element update events.
Defines Cacheonix logging configuration.
Defines the logging level. The logging level can be overridden by setting JVM system parameter
'cacheonix.logging.level' from the command line. The default logging level is 'WARNING'.
Defines if prefetch is enabled. Set to 'true' to enable prefetch. Set to 'false'
to disable prefetch. By default the prefetch is set to 'true' (enabled).
Type representing a configuration for replicated web sessions.
A store that holds data of replicated web sessions.
A unique configuration name.
Defines an abstract store for replicated web sessions.
The mandatory size of the store in bytes. If the size of the elements of elements in cache exceeds
maxBytes, Cacheonix will throw an out-of-memory exception. Example: maxBytes="5mb". Important: Cacheonix
recommends setting 'maxBytes' so that total summa of sizes of all session stores and caches doesn't
exceed 40% of JVM heap.
Defines a partitioned store for replicated web sessions. The partitioned store evenly distributes session
data and its replicas in the cluster.
The number of backup copies to be made for each session attribute.