Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix igniterealtime#43: Prevent ClassCastExceptions after plugin gets …
…reloaded in a cluster This plugin caches instances of classes that are defined in the code of the plugin. This causes ClassCastExceptions, when the plugin gets unloaded (removing the class definitions) and updated/reloaded (replacing the class definitions). The cached values at that time will refer to classes that no longer exist, causing the exceptions. https://igniterealtime.atlassian.net/browse/OF-2239 introduces a new type of Cache to work around this problem, the org.jivesoftware.util.cache.SerializingCache which is available since Openfire 4.7.0. This implementation does not cache the instance directly, but caches a serialized version instead. This way, there no longer is a reference to the class, which means that any (compatible) future class definition can be used to instantiate the cache entry again.
- Loading branch information