Hazelcast Docker Compose
This page describes how to create a Docker environment and launch a Hazelcast cluster using docker-compose
.
❗ You must first install Docker and Docker Compose. See References for download links.
# Create Hazelcast cluster with 2 members (default)
create_docker -cluster mydocker
By default, the create_docker command adds two (2) Hazelcast servers (members) in the cluster. You can change the number of servers using the -count
option. For example, the following command adds four (4) servers.
# Create Hazelcast cluster with 4 members
create_docker -cluster mydocker -count 4
cd_docker mydocker
Edit the .env
file as needed.
vi .env
There are three (3) Hazelcast configuration files as follows. Edit them as needed.
Configuration File | Cluster Type |
---|---|
padogrid/etc/hazelcast.xml |
IMDG, Jet |
padogrid/etc/hazelcast-jet.xml |
Jet |
padogrid/etc/hazelcast-client.xml |
Jet |
❗By default, the cluster name is hard-coded in the padogrid/etc/hazelcast.xml
file as dev
, even though the Docker cluster name is mydocker
in our example. If you want to keep the Hazelcast cluster name same as the Docker cluster name then uncomment the padogrid.cluster-name
system property in the padogrid/etc/hazelcast.xml
file.
❗ For Jet Management Center, the cluster member addresses are listed in the padogrid/etc/hazelcast-client.xml
file using the HOSTNAME_FOR_CLIENTS
value set in the .env
file. If you change the value of HOSTNAME_FOR_CLIENTS
then you must also make the same change in the padogrid/etc/hazelcast-client.xml
file.
vi padogrid/hazelcast.xml
Place your application jar files in the padogrid/plugins
directory, which already contains PadoGrid test jar for running perf_test
.
ls padogrid/plugins
docker-compose up
Management Center URLs are as follows:
URL | Cluster Type |
---|---|
http://localhost:8080/hazelcast-mancenter | IMDG |
http://localhost:8081 | Jet |
❗ If you have not changed the Hazelcast cluster name, then keep in mind that the Hazelcast cluster name is set to dev
by default as mentioned earlier. When you add a cluster config in Hazelcast Management Center 4.x, you must set the member addresses with the host IP address, and not localhost
.
If you have not changed the Hazelcast cluster name, you can run perf_test
as is without modifications.
create_app
cd_app perf_test; cd bin_sh
./test_ingestion -run
If you have changed the Hazelcast cluster name, then add the <cluster-name>
element in the etc/hazelcast-client.xml
file as follows:
<hazelcast...>
...
<cluster-name>mydocker</cluster-name>
...
</hazelcast>
Ctrl-C from the docker-compose up
command and prune the containers.
docker-compose down
docker container prune
- Install Docker, https://docs.docker.com/install/.
- Install Docker Compose, https://docs.docker.com/compose/install/.
PadoGrid Manual
Overview
- Home
- PadoGrid in 5 Minutes
- Quick Start
- Introduction
- Bundle Catalogs
- Building PadoGrid
- Supported Data Grid Products and Downloads
- PadoGrid Components
- Installing PadoGrid
- Root Workspaces Environments (RWEs)
- Initializing PadoGrid
- Bash Auto-Completion
- Viewing PadoGrid Summaries
- Updating Products
- Upgrading PadoGrid
- Migrating Workspaces
- PadoGrid Pods
- Kubernetes
- Docker
- Apps
- Software List
Operations
- Workspace Lifecycle Management
- Creating RWE
- Creating Workspace and Starting Cluster
- Managing Workspaces
- Understanding Workspaces
- Understanding Clusters
- Running Clusters
- Default Port Numbers
- Running Clusters Independent of PadoGrid
- Running Apps
- Understanding Groups
- Running Groups
- Understanding Bundles
- User Bundle Repos
- Using Bundle Templates
- Bundle Repo Guidelines
- User Bundle Catalogs
- Private Bundle Repos
- Gitea Repos
- Running Bundles in Container
- PadoGrid Addon Jars
- Understanding PadoGrid Pods
- Tested Vagrant Boxes
- VM-Enabled Pods
- Multitenancy
- Multitenancy Best Practices
- PadoGrid Configuration Files
Tools
Platforms
Clouds
Pado
Geode/GemFire
- Geode CLASSPATH
- Geode Kubernetes
- Geode Minikube
- Geode Minikube on WSL
- Geode Docker Compose
- Geode Grafana App
- Geode
perf_test
App - Geode WAN Example
- Geode Workspaces on VMs
- Geode on AWS EC2
- Reactivating Geode Workspaces on AWS EC2
Hazelcast/Jet
- Hazelcast CLASSPATH
- Creating Jet Workspace
- Configuring Hazelcast Addon
- HQL Query
- Hazelcast Kubernetes
- Hazelcast GKE
- Hazelcast Minikube
- Hazelcast Minikube on WSL
- Hazelcast Minishift/CDK
- Hazelcast OpenShift
- Hazelcast Docker Compose
- Hazelcast Desktop App
- Hazelcast Grafana App
- Hazelcast
jet_demo
App - Hazelcast
perf_test
App - Hazelcast WAN Example
- Hazelcast Workspaces on VMs
- Hazelcast on AWS EC2
- Reactivating Hazelcast Workspaces on AWS EC2
ComputeDB/SnappyData
Coherence
Hadoop
Kafka/Confluent
Mosquitto
- Mosquitto CLASSPATH
- Mosquitto Overview
- Installing/Building Mosquitto
- Clustering MQTT
- Cluster Archetypes
- Enabling Mosquitto SSL/TLS
- Mosquitto Docker Compose
- MQTT perf_test App
Redis
Spark