I am trying to upgrade a local OF to version 4.0.1 (and hazelcast 2.2) but during startup I sometime get this NPE:
2016.01.28 09:46:41 INFO [ClusterManager events dispatcher]: com.hazelcast.partition.InternalPartitionService - [169.254.80.80]:5701 [openfire] [3.5.1] Initializing cluster partition table first arrangement...
2016.01.28 09:46:41 WARN [ClusterManager events dispatcher]: org.jivesoftware.openfire.cluster.ClusterManager - Null value is not allowed!
java.lang.NullPointerException: Null value is not allowed!
at com.hazelcast.util.Preconditions.checkNotNull(Preconditions.java:41)
at com.hazelcast.map.impl.proxy.MapProxySupport.putAllInternal(MapProxySupport.java:862)
at com.hazelcast.map.impl.proxy.MapProxyImpl.putAll(MapProxyImpl.java:309)
at org.jivesoftware.openfire.plugin.util.cache.ClusteredCache.putAll(ClusteredCache.java:129)
at org.jivesoftware.util.cache.CacheFactory.joinedCluster(CacheFactory.java:738)
at org.jivesoftware.openfire.cluster.ClusterManager$2.run(ClusterManager.java:95)
After some trial-and-error I discovered that this happens only when restarting my OF with active clients on it, the clients reconnects before OF hits this exception and I managed to catch this my debugger:
I am also seeing this NPE in my cluster since I upgraded to 4.0.2. However, I don’t understand how configuring the member servers would resolve the NPE. FYI, I am using AWS EC2 hosts, and I think they are configured correctly.
I was thinking, if Hazelcast maps do not allow null values, then shouldn’t the Openfire Cache also disallow putting null values in them?
Is it really necessary to make these changes in the jar itself as opposed to just in the generated ./plugins/hazelcast/classes/hazelcast-cache-config.xml file?
I’m definitely seeing the same issues on my install - overall the hazelcast clustering seems incredibly flakey for restarts/failure events/etc. - and I’m not 100% certain, but it looks like the weirdness in it may also be affecting the behavior of S2S connections.