In general, it is recommended to use VMware Tanzu GemFire for VMware Tanzu Application Service (TAS) for VMs deployed applications that use GemFire. PCC is built on top of GemFire. VMware Tanzu GemFire is TAS for VMs backing service implementation from VMware GemFire. TAS for VMs provides high availability for services like VMware Tanzu GemFire. VMware Tanzu GemFire is configured to be fault tolerant by default. It reduces the potential for data loss during a network segmentation outage by being configured to hold multiple copies of data across multiple TAS for VMs availability zones. This reduces the possibility that all multiple copies of a given entry will be on the losing side of a network split.
VMware GemFire can also be used by TAS for VMs applications as an external service, but without the benefits previously mentioned. The VMware GemFire cluster(s) will have to be managed by an administrator and or custom management scripts. Many of the needed custom and manual operations are included in by default.
This article will describe how to migrate from VMware GemFire to VMware Tanzu GemFire with detailed information and steps.
VMware Tanzu Gemfire does not support the use of Cache XML based configurations. You must use the cluster configuration service to configure and manage VMware Tanzu Gemfire clusters. The configuration is created using the gfsh shell. The cluster configuration service helps to automate the deployment and operation of VMware Gemfire/VMware Tanzu GemFire.
A single gfsh file containing multiple cluster creation statements can be used to replace a cache.xml. See the following link for mapping cache.xml configurations to gfsh scripts:
https://docs.vmware.com/en/VMware-GemFire/10.0/gf/tools_modules-gfsh-chapter_overview.html
If the resource management for eviction is set in the cache.xml such as the following:
<resource-manager eviction-heap-percentage="80" critical-heap-percentage="95" />
Or if the resource management is set during cache server startup:
gfsh>start server --name=Server1 --eviction-heap-percentage=80
These should be removed. VMware Tanzu GemFire manages its own eviction heap percentage policies.
VMware Tanzu GemFire includes a default security plug-in implementation.
Currently, VMware Tanzu Gemfire service instances are created with three default GemFire user roles for interacting with clusters:
All client apps, gfsh, and JMX clients must authenticate as one of these user roles to access the cluster. Each user role is given predefined permissions for cluster operations.
The latest version of VMware Tanzu Gemfire supports persistence and overflow of data using disk stores. Use gfsh over HTTPS to connect to the VMware Tanzu Gemfire service instance using the cluster operator credentials. Connecting gfsh via JMX is not supported.
Use relative paths for disk store directory instead of absolute paths.
create disk-store --name=<name-of-disk-store> --dir=<relative/path/to/diskstore/directory>
The relative path will be created within /var/vcap/store/gemfire-server/.
VMware Tanzu GemFire clusters and brokers stream logs containing service metrics into TAS for VMs Loggregator Firehose. You can use any tool that has a corresponding TAS for VMs nozzle to read and monitor these metrics in real time. This allows standard monitoring and logging tools (such as Prometheus and Grafana) to read and monitor these metrics in real time.
Refer to the following documentation for metrics and Key Performance Indicators (KPI(s)) that should be monitored and take the appropriate actions.
You can use the VMware GemFire export/import gfsh statements to move data set to VMware Tanzu GemFire. It is recommended to use parallel export from your existing VMware GemFire cluster to partition the data based on members.
export data --region=$region --dir=$BACKUP_DIR --member=$member --parallel=true
It is recommended to also use parallel import into VMware Tanzu Gemfire.
import data --region=$region --dir=$BACKUP_DIR --member=$member --parallel=true
Execute a rebalance command after data is imported into VMware Tanzu Gemfire.
VMware Tanzu GemFire does not expose changing the CLASSPATH of the VMware Tanzu GemFire members. Instead, use the gfsh deploy Jar command to deploy custom code.
This includes Functions, Domain/Data objects, Cache Writer/Loaders, Cache Listener, AsyncEventListener, PartitionListener, etc.
Example deploy Jar command.
deploy --jar=$1
Deployed jars are pushed to each member in the cluster and added to its CLASSPATH dynamically. The class can be referenced after the deploy command is executed.
For example, the following configures a cache listener on a “test” region after a Jar containing the class is deployed.
deploy --jar=/jars/exampleCacheListener.jar create region --name=/test --cache-listener=my.exampleCacheListener --type=PARTITION
Domain objects should implement org.apache.geode.DataSerializable interface if GemFire Data Serialization option is needed.
When Data Serialization or server-side code is used, it is also recommended to deploy the jars using the gfsh deploy jar command.