Interface BridgeEvent

All Superinterfaces:
BaseBridgeEvent, Completable<Boolean>, Promise<Boolean>

public interface BridgeEvent extends BaseBridgeEvent
Represents an event that occurs on the gRPC event bus bridge.

Bridge events are generated when clients interact with the EventBus through the gRPC bridge. These events can be used to implement custom authorization logic, logging, or monitoring.

Events include:

  • SEND - When a client sends a message to an address
  • PUBLISH - When a client publishes a message to an address
  • RECEIVE - When a client receives a message from an address it has subscribed to
  • REGISTER - When a client registers a handler for an address
  • UNREGISTER - When a client unregisters a handler for an address

Each event can be allowed or denied by calling the setHandler method.

  • Method Details

    • setRawMessage

      BridgeEvent setRawMessage(JsonObject message)
      Sets the raw JSON message for this bridge event.

      The raw message contains the actual data being sent over the EventBus. This method allows modifying the message content before it's processed, which can be useful for message transformation or content filtering.

      Specified by:
      setRawMessage in interface BaseBridgeEvent
      Parameters:
      message - the raw JSON message to set
      Returns:
      this reference, so it can be used fluently in method chaining