Hazelcast AWS EC2 Instance Auto Discovery
Hazelcast supports EC2 auto discovery. This configuration is useful when you don’t want to list all the IPs by your hand. The discovery feature is provided as a Hazelcast plugin.
Starting from Hazelcast 3.7.3, hazelcast-cloud module has been renamed as hazelcast-aws module. If you want to use AWS Discovery, you should add the library hazelcast-aws to your environment.
There are two possible ways to configure your cluster to use EC2 auto-discovery. You can either choose to configure your cluster with AwsConfig (or aws element in your XML config) OR you can choose configuring AWS discovery using Discovery SPI implementation. (from hazelcast-aws-1.2, it’s strongly recommended to use Discovery SPI implementation)
If you have IAM configured in AWS, access-key and secret-key aren’t required (vice-versa). Since the AWS endpoints are per-region, not per AZ, don’t append sub region (a/b/c..) such as eu-west-1a or eu-west-1b etc. security-group-name, tags and port fields are optional.
If you run the program in several AWS EC2 instances, Hazecast nodes will discover each other. Voila! Now you have the big area to play :D
For further information, visit hazelcast-aws Github repository.