Package com.eventstore.dbclient
Class PersistentSubscriptionListener
- java.lang.Object
-
- com.eventstore.dbclient.PersistentSubscriptionListener
-
public abstract class PersistentSubscriptionListener extends java.lang.ObjectListener used to handle persistent subscription notifications raised throughout its lifecycle.
-
-
Constructor Summary
Constructors Constructor Description PersistentSubscriptionListener()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidonCancelled(PersistentSubscription subscription)Called when the subscription is cancelled or dropped.voidonConfirmation(PersistentSubscription subscription)voidonError(PersistentSubscription subscription, java.lang.Throwable throwable)Called when an exception was raised when processing an event.voidonEvent(PersistentSubscription subscription, int retryCount, ResolvedEvent event)Called when EventStoreDB sends an event to the persistent subscription.
-
-
-
Method Detail
-
onEvent
public void onEvent(PersistentSubscription subscription, int retryCount, ResolvedEvent event)
Called when EventStoreDB sends an event to the persistent subscription.- Parameters:
subscription- handle to the persistent subscription.retryCount- how many times the event was retried.event- a resolved event.
-
onError
public void onError(PersistentSubscription subscription, java.lang.Throwable throwable)
Called when an exception was raised when processing an event.- Parameters:
subscription- handle to the persistent subscription.throwable- an exception.
-
onCancelled
public void onCancelled(PersistentSubscription subscription)
Called when the subscription is cancelled or dropped.- Parameters:
subscription- handle to the persistent subscription.
-
onConfirmation
public void onConfirmation(PersistentSubscription subscription)
-
-