PEPService fails to be added to a clustered Cache

Description

After adding Hazelcast to the XMPP domain at igniterealtime.org, I noticed stack traces like these in the error log:

The root cause lies in org.jivesoftware.openfire.pep.PEPServiceManager#pepServices, which is a cache of PEPService instances. When used in a cluster, it tries to serialize PEPService instances, which fails. The AdHocCommandManager that is part of the instance (org.jivesoftware.openfire.pep.PEPService#adHocCommandManager) is not Serializable.

The obvious way out would be making that class Serializable. I do wonder if that's not adding to much to an already rather bloated cached entity.

Environment

None

Activity

Show:
Daryl Herzmann
January 4, 2013, 1:41 PM

Thanks, dogfooded just now and did not get any errors. Will mark as fixed

Tom Evans
January 4, 2013, 9:06 AM

Ready for dogfooding ... if you dare!

Tom Evans
January 4, 2013, 9:04 AM

Yikes! Hope there's no "3-stikes" rule in effect ... apologies for the churn. How quickly race conditions turn into steeplechases.

Anyway - It seems we were switching to the clustered factory strategy class prematurely (after initiating the cluster start, but before the server had actually joined the cluster). I have applied another small change to the CacheFactory (SVN 13383) to correct this timing problem.

Daryl Herzmann
January 3, 2013, 6:06 PM

Didn't appear to work and another bug appeared

Tom Evans
January 3, 2013, 5:52 PM

Looks like a timing issue during cluster startup. I have added some synchronization to the CacheFactory that should fix this (SVN 13382).

Fixed
Your pinned fields
Click on the next to a field label to start pinning.

Assignee

Tom Evans

Reporter

Guus der Kinderen