I think it is best to wire all this stuff in the Hazelcast xml configuration file. So that it doesn't need to be done programmatically. But this way the easiest way to get things up and running.

I can pull it out and move it to the Hazelcast xml file.