To install Hazelcast Enterprise Edition, you can use Docker, the binary, or Java. To unlock the Enterprise Edition features, you must install your Enterprise Edition license key.
These instructions apply only to the licensed Enterprise Edition. If you have the Community Edition edition, follow the instructions in the Install Hazelcast Community Edition topic. If you are moving members from an Community Edition cluster to an Enterprise Edition cluster of the same version, you can use rolling restarts to move each member without downtime. For further information on moving members from an Community Edition cluster to a target Enterprise Edition, see Move to Enterprise Edition from Community Edition. |
For further information on the available editions and distributions, see the Hazelcast editions and distributions topic.
Use Enterprise Edition Docker image
-
Check that Docker is correctly installed, using the following command:
docker version
If you don’t see a version number, see the Docker docs for troubleshooting information.
-
Pull the latest Docker image
docker pull hazelcast/hazelcast-enterprise:5.7.0-SNAPSHOT
-
Check that Hazelcast Platform is correctly installed, using the following command:
hz -V
You should see something like:
Version: 5.7.0-SNAPSHOT
Use Enterprise Edition binary
-
Download and extract the Enterprise Edition zip file from the Hazelcast repository.
-
Check that Hazelcast Platform is correctly installed, using the following command:
hz -V
You should see something like:
Version: 5.7.0-SNAPSHOT
Use Enterprise Edition with Java
To install Hazelcast with Java, you can use one of the following:
-
Maven
-
JAR file
-
Modular Java
Using Maven
Hazelcast runs on Java, which means you can add it as a dependency in your Java project.
The Java package includes both a member API and a Java client API. The member API is for embedded topologies where you want to deploy and manage a cluster in the same Java Virtual Machine (JVM) as your applications. The Java client is for connecting to an existing member in a client/server topology, such as Hazelcast Cloud.
-
Download and install a supported JDK.
-
Add the following to your
pom.xml
file.<repositories> <repository> <id>private-repository</id> <name>Hazelcast Private Snapshot Repository</name> <url>https://repository.hazelcast.com/snapshot/</url> (1) <releases> <enabled>false</enabled> </releases> </repository> </repositories> <dependencies> <dependency> <groupId>com.hazelcast</groupId> <artifactId>hazelcast-enterprise</artifactId> (2) <version>5.7.0-SNAPSHOT</version> (3) </dependency> </dependencies>
1 Location for Maven to access Hazelcast artifacts. 2 Hazelcast Enterprise Edition dependency. 3 Hazelcast Enterprise Edition version. -
Check that Hazelcast Platform is correctly installed, using the following command:
hz -V
You should see something like:
Version: 5.7.0-SNAPSHOT
Use modular Java
You can use Hazelcast as a module in the Java Platform Module System (JPMS).
To run your application with Hazelcast libraries on the module path, use com.hazelcast.core
for the hazelcast-5.7.0-SNAPSHOT.jar
module name.
If you use JPMS, it enforces stricter visibility rules and Hazelcast uses the internal Java API to reach the best performance results.
Hazelcast needs the java.se
module and access to the following Java
packages:
-
java.base/jdk.internal.ref
-
java.base/java.nio
(reflective access) -
java.base/sun.nio.ch
(reflective access) -
java.base/java.lang
(reflective access) -
jdk.management/com.ibm.lang.management.internal
(reflective access) -
jdk.management/com.sun.management.internal
(reflective access) -
java.management/sun.management
(reflective access)
You can provide access to these packages by using simple
--add-exports
and --add-opens
(for reflective access) Java arguments.
java --add-modules java.se \
--add-exports java.base/jdk.internal.ref=ALL-UNNAMED \
--add-opens java.base/java.lang=ALL-UNNAMED \
--add-opens java.base/java.nio=ALL-UNNAMED \
--add-opens java.base/sun.nio.ch=ALL-UNNAMED \
--add-opens java.management/sun.management=ALL-UNNAMED \
--add-opens jdk.management/com.ibm.lang.management.internal=ALL-UNNAMED \
--add-opens jdk.management/com.sun.management.internal=ALL-UNNAMED \
-jar hazelcast-5.7.0-SNAPSHOT.jar
java --add-modules java.se \
--add-exports java.base/jdk.internal.ref=com.hazelcast.core \
--add-opens java.base/java.lang=com.hazelcast.core \
--add-opens java.base/java.nio=com.hazelcast.core \
--add-opens java.base/sun.nio.ch=com.hazelcast.core \
--add-opens java.management/sun.management=com.hazelcast.core \
--add-opens jdk.management/com.ibm.lang.management.internal=com.hazelcast.core \
--add-opens jdk.management/com.sun.management.internal=com.hazelcast.core \
--module-path lib \ (1)
--module com.hazelcast.core/com.hazelcast.core.server.HazelcastMemberStarter
1 | This example expects the hazelcast-5.7.0-SNAPSHOT.jar file in the lib directory. |
Get an Enterprise Edition license key
Hazelcast Enterprise Edition requires a license key. You can get a 10-day trial license from the Hazelcast website.
-
Complete the form on the Hazelcast website
-
Check your email for an automated email from [email protected]
-
You should have a license key that looks like:
TrialLicense#10Nodes#eyJhbGxvd2VkTmF0aXZlTWVtb3J5U2l6ZSI6MTAwLCJhbGxvd2VkTnVtYmVyT2ZOb2RlcyI6MTAsImFsbG93ZWRUaWVyZWRTdG9yZVNpemUiOjAsImFsbG93ZWRUcGNDb3JlcyI6MCwiY3JlYXRpb25EYXRlIjoxNzUyMTU0ODYzLjMxODUyNzg2MSwiZXhwaXJ5RGF0ZSI6MTc1NDY5NzU5OS45OTk5OTk5OTksImZlYXR1cmVzIjpbMCwyLDMsNCw1LDYsNyw4LDEwLDExLDEzLDE0LDE1LDE3LDIxLDIyXSwiZ3JhY2VQZXJpb2QiOjAsImhhemVsY2FzdFZlcnNpb24iOjk5LCJvZW0iOmZhbHNlLCJ0cmlhbCI6dHJ1ZSwidmVyc2lvbiI6IlY3In0=.enSTWffnYK_rBdTC7LOVISPYYaEfwdM7giv8ZBH4iq2b5vHuA5U-OswteJUmF8jHXyyo9j0oKBWkvgxe6PBKAQ==
In any provided code examples in this documentation, you should replace any instances of <YOUR_LICENSE_KEY> with your specific license key.
Install an Enterprise Edition license key
To use Hazelcast Enterprise Edition, you need to add a license key for all members in a cluster.
Hazelcast Enterprise Edition license keys are only required for members. You don’t need to set a license key for Java clients that are connected to members. |
Replace <YOUR_LICENSE_KEY>
with your official license key.
<hazelcast>
<license-key><YOUR_LICENSE_KEY></license-key>
</hazelcast>
Replace <YOUR_LICENSE_KEY>
with your official license key.
hazelcast:
license-key: <YOUR_LICENSE_KEY>
Replace <YOUR_LICENSE_KEY>
with your official license key.
Add your license using the setLicenseKey()
method:
Config config = new Config();
config.setLicenseKey( "<YOUR_LICENSE_KEY>" );
HZ_LICENSEKEY=<YOUR_LICENSE_KEY>
-Dhazelcast.enterprise.license.key=<YOUR_LICENSE_KEY>
Next steps
Learn more about Enterprise Edition license keys.
Get started with the Hazelcast Enterprise Edition features with a series of tutorials.