Interface ReplicationContext


  • public interface ReplicationContext
    Provides access to replication specific state

    Not for user extension

    • Method Detail

      • concurrent

        boolean concurrent()
        Must only be called from the event handler
        Returns:
        true if this event happened concurrent with an event from another replica
      • currentTimeMillis

        long currentTimeMillis()
        Returns:
        a timestamp that will always be increasing (is monotonic)
      • entityId

        java.lang.String entityId()
        Returns:
        The unique id of this replica, not including the replica id
      • getAllReplicas

        java.util.Set<ReplicaId> getAllReplicas()
        Returns:
        The ids of all replicas of this replicated event sourced actor
      • origin

        ReplicaId origin()
        Must only be called from the event handler
        Returns:
        the replica id where the current event was persisted
      • persistenceId

        PersistenceId persistenceId()
        Returns:
        The unique id of this replica, including the replica id
      • recoveryRunning

        boolean recoveryRunning()
        Must only be called from the event handler
        Returns:
        true when the event handler is invoked during recovery.
      • replicaId

        ReplicaId replicaId()
        Returns:
        The replica id of this replicated event sourced actor