The current implementation of org.jivesoftware.util.cache.Cache imposes no particular constraints on the keys and values placed within it.
However, whilst the implementation org.jivesoftware.util.cache.DefaultCache will happily take null or non-serializable keys, the constraints of Hazelcast mean that org.jivesoftware.openfire.plugin.util.cache.ClusteredCache must take serializable, non-null keys.
The current implementation of org.jivesoftware.util.cache.Cache imposes no particular constraints on the keys and values placed within it.
However, whilst the implementation org.jivesoftware.util.cache.DefaultCache will happily take null or non-serializable keys, the constraints of Hazelcast mean that org.jivesoftware.openfire.plugin.util.cache.ClusteredCache must take serializable, non-null keys.
This can lead to bugs - for example OF-1480, the original implementation of https://igniterealtime.atlassian.net/browse/OF-1539#icft=OF-1539
To avoid this, DefaultCache should enforce non-null, serializable keys and values.