Remindable 接口


Interface which actors that use reminders must implement.

public interface Remindable


receiveReminderAsync(String reminderName, byte[] context, Duration timeSpan, Duration period)

Reminder call back invoked when an actor reminder is triggered.

Remarks: When a reminder is triggered, Actors runtime will invoke receiveReminderAsync method on the Actor. An actor can register multiple reminders and the ReceiveReminderAsync method is invoked any time any of those reminders is triggered. The actor can use the reminder name that is passed in to the receiveReminderAsync method to figure out which reminder was triggered. The Actors runtime saves the actor state when the receiveReminderAsync call completes. If an error occurs in saving the state, that actor object will be deactivated and a new instance will be activated, to specify that the state need not be saved upon completion of the reminder.