Deploying Cluster-Side Modules to Cloud Clusters
Before clusters can execute or store your cluster-side modules, they need to be packaged into a single file and uploaded to the cluster as custom classes. You can upload cluster-side modules, using the console, or the Maven plugin.
Before you Begin
Check the requirements and limitations for cluster-side modules to make sure that your code is ready to be packaged.
Uploading Cluster-Side Modules
Clusters expect all modules to be packaged into a single ZIP or JAR file. When you’ve built and packaged your cluster-side modules, the final step is to upload the resulting package file to the cluster.
You can upload custom classes, using the following options:
-
Maven plugin
-
Cloud console
Using the Maven Plugin
Cloud Standard
-
Configure the Cloud Maven plugin in your
pom.xml
file. -
Change into your project’s root directory.
-
Execute the
deploy
goal to package your project into a JAR file and upload it to the configured cluster.mvn clean package hazelcast-cloud:deploy
In the output, you should see that the plugin packaged and deployed your JAR to your Cloud Standard cluster.
Using the Cloud Console
To upload code to Cloud:
-
Use your build tool such as Gradle or Maven to package the classes into a JAR or ZIP file.
-
Sign into the Cloud console and select your cluster.
-
Go to Manage > Custom Classes and upload your file to Cloud.
When the file is uploaded and ready to use, you will see a success message.
Removing Cluster-Side Modules
To remove cluster-side modules from the cluster, you must use the Cloud console.
-
Sign into the Cloud console and select your cluster.
-
Go to Manage > Custom Classes and find your class in the list.
-
Click on the delete icon next to the class that you want to delete.
Downloading Cluster-Side Modules
To download a cluster-side module, you must use the Cloud console.
-
Sign into the Cloud console.
-
Go to Manage > Custom Classes, find your class in the Uploaded Classes list and click on it.