Class TopologyChange

java.lang.Object
org.axonframework.axonserver.connector.TopologyChange

public class TopologyChange extends Object
Object representing a topology change at Axon Server.

Topology changes can be acted upon by registering a TopologyChangeListener.

Since:
4.12.0
Author:
Steven van Beelen
See Also:
  • Constructor Details

    • TopologyChange

      public TopologyChange(TopologyChange.Type type, String context, String clientId, String clientStreamId, String componentName, TopologyChange.HandlerSubscription handlerSubscription)
      Constructs a TopologyChange based on the give type, context, clientId, clientStreamId, componentName, and handler.
      Parameters:
      type - The type of the TopologyChange.
      context - The context for which a TopologyChange occurred.
      clientId - The client identifier for which a TopologyChange occurred.
      clientStreamId - The client stream identifier for which a TopologyChange occurred.
      componentName - The component name for which a TopologyChange occurred.
      handlerSubscription - The TopologyChange.HandlerSubscription for which a TopologyChange occurred. Should be null for the Type RESET.
    • TopologyChange

      public TopologyChange(io.axoniq.axonserver.grpc.control.TopologyChange change)
      Constructs a TopologyChange based on the given gRPC change.
      Parameters:
      change - The gRPC TopologyChange to construct an Axon Framework TopologyChange from.
  • Method Details

    • type

      public TopologyChange.Type type()
      Returns the Type of the TopologyChange.
      Returns:
      The Type of the TopologyChange.
    • context

      public String context()
      Returns the context for which a TopologyChange occurred.
      Returns:
      The context for which a TopologyChange occurred.
    • clientId

      public String clientId()
      Returns the client identifier for which a TopologyChange occurred.
      Returns:
      The client identifier for which a TopologyChange occurred.
    • clientStreamId

      public String clientStreamId()
      Returns the client stream identifier for which a TopologyChange occurred.
      Returns:
      The client stream identifier for which a TopologyChange occurred.
    • componentName

      public String componentName()
      Returns the component name for which a TopologyChange occurred.
      Returns:
      The component name for which a TopologyChange occurred.
    • handler

      Returns the HandlerSubscription for which a TopologyChange occurred.

      Is null when type() returns TopologyChange.Type.RESET.

      Returns:
      The HandlerSubscription for which a TopologyChange occurred.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object