Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Groovy script to seed Hazelcast instance for ExecuteScript example
@Grab(group='com.hazelcast', module='hazelcast', version='3.6')
@Grab(group='com.hazelcast', module='hazelcast-client', version='3.6')
import com.hazelcast.client.*
import com.hazelcast.client.config.*
import com.hazelcast.core.*
ClientConfig clientConfig = new ClientConfig();
clientConfig.getNetworkConfig().addAddress("", "");
client = HazelcastClient.newHazelcastClient(clientConfig)
client.getMap("customers").put('mattyb149', ['name': 'Matt Burgess', 'email': '', 'blog': ''])
client.getMap("customers").put('nifi', ['name': 'Apache NiFi', 'email': '', 'blog': ''])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment