Skip to content

IGrainContext.Migrate(Dictionary<string, object>, CancellationToken)

Migrate(Dictionary<string, object>, CancellationToken)

abstract
public abstract void Migrate(Dictionary<string, object>? requestContext, CancellationToken cancellationToken = default(CancellationToken))
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.

Parameters

requestContextDictionary<string, object>
The request context, which is provided to the placement director so that it can be examined when selecting a new location.
cancellationTokenCancellationToken
A cancellation token which, when canceled, indicates that the process should complete promptly.