The following PAC and SOR environment variables are provided for reference purposes only.
All enterprise server instances that are part of a
PAC need to have the following environment variable set:
ES_PAC=pacname
Each
SOR within a PAC needs a specific environment variable set:
ES_SCALE_OUT_REPOS_n=sorName=sorType,connectionDetails##[TMP#][models]
Note: The same environment variable must be specified on each region that joins a PAC. Only one environment variable can reference
the
PAC Scale-Out Repository (PSOR), as only one
PSOR can be associated with any given
PAC.
where:
- n
-
This is the SOR number and can be a value 1 to 9.
-
sorName
- This is the name of the SOR and must not contain spaces.
In the context of using Redis, the
sorName is used to retrieve the Redis master from Redis.
- sorType
- This is the type of data store being used and can be:
- redis
- redis_TLS
- coherence
Use redis_TLS for TLS enabled connections to a Redis data store. See
Redis Requirements and Configuration as a Scale-Out Repository for more information.
-
connectionDetails
- For Redis this is the host name and port number of the scale out repository, in the form
host:port. For example,
localhost:6379. You can specify multiple connections by using a comma as a delimiter between each connection.
For Oracle Coherence the connection string is limited to 1024 characters and takes the form:
[userid@][configfile][,property=[value]]…
where:
- userid
- This is the optional user to use when Oracle Coherence security is enabled.
- configfile
- This is the name, location, URL of the cache configuration file. If this is omitted it defaults to
mfes-cache-config.xml.
- property
- This is the name of a Java property to set to the value or is clear if
value is unspecified.
- value
- This is the value of the Java property to set.
The configuration used by the
Enterprise Server clients should match the server configuration. So where for a Redis you might have:
ES_SCALE_OUT_REPOS_1=MySOR=redis,127.0.0.1:6379##TMP#
For Oracle Coherence you might have:
ES_SCALE_OUT_REPOS_1=MySOR=coherence,mfes-cache-config.xml,coherence.cluster=MyPAC_cluster,mfescache.wka.MyPAC_cluster=127.0.0.1:7574##TMP#
If you are using the default
mfes-cache-config.xml filename you can omit its name and just specify the properties. For example:
ES_SCALE_OUT_REPOS_1=MySOR=coherence,,coherence.cluster=MyPAC_cluster,mfescache.wka.MyPAC_cluster=127.0.0.1##TMP#
Note: There are two adjacent comma characters where the configuration file name is missing.
The configuration file
mfescache.cfg is used to specify options when
Enterprise Server is starting the Java Virtual Machine (JVM). This file can be modified to specify properties in addition to the connection
string properties, if specified in both, then the connection string property will override the configuration file value.
- TMP
- Indicates that this is a PSOR that stores active resources.
Note: You must specify exactly one PSOR for each enterprise server instance within a PAC and each enterprise server instance in
the PAC must use the same PSOR.
- models
- Take the form:
=ResourceType=model[:model][#ResourceType=model[:model]]
where:
- #
- Delimits the set of models for a model type.
- ResourceType
- The resource type can be Temporary Storage (TS) or Transient Data (TD). Permitted values are TS and TD.
- model
- Specified as a string between 0-16 bytes long. TD names can only be four characters long. TS names can be up to 16 characters
long. The string names support the use of the following wildcards:
- *
- Matches any string of characters.
- +
- Matches any one character.
Note: Trailing + wildcards are used to pad missing characters appropriate for the resource type. For example, if you are specifying
a model for a TD resource type and only specify a single letter "A" then it is treated as "A+++".
- :
- Delimits between each model.
- x'hex string'
- A hexadecimal prefix can be specified in a SOR model by enclosing the hex string in quotes and preceding it with an x, for
example, x'ABAB' or x'AABBCC'.
You can use 2B as a generic matching character, for example, x'AA2BAA' would match queues that begin with x'AAAAAA', x'AABBAA',
and x'AACCAA' and so on.
Examples
The following is an example of the ES_SCALE_OUT_REPOS_n environment variable using Redis as the SOR:
ES_SCALE_OUT_REPOS_1=RedisLocal=redis,127.0.0.1:12345##TMP#TD=AC*:TD*:RTDQ:SOR1#TS=A*:B+A:NRQSOR1
where:
- RedisLocal
- This specifies the name that will be used by Redis to identify the Redis master in a sentinel configuration.
- redis
- This specifies that Redis is the type of SOR being used.
- 127.0.0.1:12345
- This specifies the Redis server connection details: ip address and port for this SOR.
- ##TMP#
- This specifies that this SOR is the mandatory PSOR.
- TD=AC*:TD*:RTDQ:SOR1#TS=A*:B+A:NRQSOR1
-
This specifies that the SOR will contain TDs starting with AC, TD, and a TD called RTDQ as well as all TSs starting with
an A, those starting with a B followed by any character and ending with an A, and a TS called NRQSOR1.
The following is an example of how you can specify more Redis SORs on a PAC:
ES_SCALE_OUT_REPOS_2=RedisLocal2=redis,127.0.0.1:67891##TD=ATD#TS=T*R2:R*R2
where:
-
RedisLocal2
- This specifies the name that will be used by Redis to identify the Redis master.
- redis
- This specifies that Redis is the type of SOR being used.
-
127.0.0.1:67891
- This specifies the connection details for a second Redis server: ip address and port for this SOR.
- ##TD=ATD#TS=T*R2:R*R2
- This specifies that the SOR will contain a TD called ATD, as well as TS that start with T and end with R2, and that start
with R and end with R2.