Community
Participate
Working Groups
In Gyrex clusters we currently don't have any event distribution mechanism between the nodes of a cluster.
Modified summary to better reflect the goal proposed by the review. https://git.eclipse.org/r/24823 Andreas, thanks for bringing this up. Would like to get this into 1.3 if possible. Let's continue on the Gerrit review. Assigning to you because you provided the review. :)
Andreas, see https://git.eclipse.org/r/24955 for a proposal for a more broad distributed event bus which is capable of working with different event types.
FYI: https://git.eclipse.org/r/24955 is about to be merged into master. It includes the EventBus OSGi service which can be used. It also supports dependency injection of ITopic instances.
Merged https://git.eclipse.org/r/24955. Now awaiting the web socket based implementation. :)
When testing the websocket based impl, I use a cluster of three nodes. The event is correctly sent out from the origin node to the two others. On one node it is received and processed correctly, but on the other node I get the following exception: 13:14:41.497 [qtp619071041-28] WARN o.e.g.e.w.i.EventMessageReceiver - Unhandled Error (closing connection) java.lang.NullPointerException: null at org.eclipse.gyrex.eventbus.internal.Topic.dispatchEvent(Topic.java:138) ~[na:na] at org.eclipse.gyrex.eventbus.internal.EventService$TopicEventReceiver.receiveEvent(EventService.java:69) ~[na:na] at org.eclipse.gyrex.eventbus.websocket.internal.WebsocketEventTransport.distributeEventToSubscribers(WebsocketEventTransport.java:271) ~[na:na] at org.eclipse.gyrex.eventbus.websocket.internal.WebsocketEventTransport$4.onEventMessage(WebsocketEventTransport.java:342) ~[na:na] at org.eclipse.gyrex.eventbus.websocket.internal.EventMessageReceiver.onWebSocketBinary(EventMessageReceiver.java:53) ~[na:na] All nodes operate on the same codebase, I'm still in investigation, whats going on here
found the problem: The EventMessage Object isn't designed to be sent more than once, becaus ethe ByteBuffer payload is read out, when sending the event to the first node, sending the same eventMessage to the next node results in an already empty payload
Oh well... https://git.eclipse.org/r/28525
Confirmed the fix by writing a unit test.
Andreas, I'm marking this as fixed because 1.3 is done. Please open new bugs for problems found in the current implementation.