GrainBaseExtensions Class

Definition

Helper methods for IGrainBase implementations.

public static class GrainBaseExtensions
type GrainBaseExtensions = class
Public Module GrainBaseExtensions
Inheritance
GrainBaseExtensions

Methods

DeactivateOnIdle(IGrainBase)

Deactivate this grain activation after the current grain method call is completed. This call will mark this activation of the current grain to be deactivated and removed at the end of the current method. The next call to this grain will result in a different activation to be used, which typical means a new activation will be created automatically by the runtime.

MigrateOnIdle(IGrainBase)

Starts an attempt to migrating this instance to another location. Migration captures the current RequestContext, making it available to the activation's placement director so that it can consider it when selecting a new location. Migration will occur asynchronously, when no requests are executing, and will not occur if the activation's placement director does not select an alternative location.

Applies to