Class HazelcastClusterEventWrapper<T extends ClusterEvent>
java.lang.Object
java.util.EventObject
com.atlassian.confluence.event.events.cluster.ClusterEventWrapper
com.atlassian.confluence.cluster.hazelcast.HazelcastClusterEventWrapper<T>
- All Implemented Interfaces:
com.hazelcast.nio.serialization.DataSerializable,Serializable
public class HazelcastClusterEventWrapper<T extends ClusterEvent>
extends ClusterEventWrapper
implements Serializable, com.hazelcast.nio.serialization.DataSerializable
Hazelcast specific implementation of the ClusterEventWrapper. This version is DataSerializable, and uses OsgiSafe
to hold the event. This allows Hazelcast to serialize/deserialze it nicely
- See Also:
-
Field Summary
Fields inherited from class com.atlassian.confluence.event.events.cluster.ClusterEventWrapper
eventFields inherited from class java.util.EventObject
source -
Constructor Summary
ConstructorsConstructorDescriptionHazelcastClusterEventWrapper(Object src, T event) Create a clustered wrapper event to broadcast an event across a cluster. -
Method Summary
Methods inherited from class com.atlassian.confluence.event.events.cluster.ClusterEventWrapper
unwrapIfTypeMethods inherited from class java.util.EventObject
getSource, toString
-
Constructor Details
-
HazelcastClusterEventWrapper
Create a clustered wrapper event to broadcast an event across a cluster.- Parameters:
src- an Object which represents where the event came from. In the case of clustered events, the recommended src value is aClusterNodeInformationobject.event- an event to be wrapped
-
HazelcastClusterEventWrapper
public HazelcastClusterEventWrapper()
-
-
Method Details
-
getEvent
- Overrides:
getEventin classClusterEventWrapper- Returns:
- the wrapped event
-
writeData
- Specified by:
writeDatain interfacecom.hazelcast.nio.serialization.DataSerializable- Throws:
IOException
-
readData
- Specified by:
readDatain interfacecom.hazelcast.nio.serialization.DataSerializable- Throws:
IOException
-