Ensure the Cache is Serializable, non-null

Description

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 

To avoid this, DefaultCache should enforce non-null, serializable keys and values.

Environment

None
Fixed

Assignee

Greg Thomas

Reporter

Greg Thomas

Labels

None

Expected Effort

None

Ignite Forum URL

None

Components

Fix versions

Affects versions

Priority

Major
Configure