System Agnostic Way of Installing Hazelcast

Use Maven to download the Hazelcast binary:

$ mvn dependency:get -Dartifact='com.hazelcast:hazelcast:5.5.0'

Start it with java without any systemd or /usr/bin wrapper:

$ java -jar ~/.m2/repository/com/hazelcast/hazelcast/5.5.0/hazelcast-5.5.0.jar

If you want to enable the REST API, you can set these environment variables in front of the java command:

$ HZ_NETWORK_RESTAPI_ENABLED=true \
  HZ_NETWORK_RESTAPI_ENDPOINTGROUPS_DATA_ENABLED=true \
  java -jar ~/.m2/repository/com/hazelcast/hazelcast/5.5.0/hazelcast-5.5.0.jar

That's it. Hazelcast is now running on your machine. You can test it out by creating an entry:

$ curl \
  --include \
  --header "Content-Type: text/plain" \
  --data "bar" \
  http://localhost:5701/hazelcast/rest/maps/mapName/foo

And then retrieve it again:

$ curl --include http://localhost:5701/hazelcast/rest/maps/mapName/foo
HTTP/1.1 200 OK
Content-Type: text/plain
Content-Length: 3

bar

~ /home 🏠 ~ talks 💬 ~ bash ~ craftsmanship ~ db ~ dongxi ~ emacs ~ escenic ~ iam ~ java ~ js ~ language ~ latex ~ ldap ~ life ~ linux ~ llm ~ mac-os-x ~ mt-foo ~ network ~ norsk ~ python ~ quotes ~ running ~ security ~ travel ~ unix ~ various ~ vcs ~ webdesign ~ windows ~ discoveries ~ cv 🧙 ~

Licensed under CC BY Creative Commons License ~ 📡 RSS feed ~ ✉ torstein.k.johansen @ gmail ~ 🐘 @skybert@hachyderm.io ~ 🎥 youtube.com/@skybert