Edit

Share via


PreferLocalPlacement Class

Definition

The prefer local placement strategy indicates that a grain should always be placed on the local host if the grain is not already active elsewhere in the cluster and the local host is compatible with it.

[System.Serializable]
public class PreferLocalPlacement : Orleans.Runtime.PlacementStrategy
[System.Serializable]
[Orleans.GenerateSerializer]
[Orleans.Immutable]
[Orleans.SuppressReferenceTracking]
public sealed class PreferLocalPlacement : Orleans.Runtime.PlacementStrategy
[<System.Serializable>]
type PreferLocalPlacement = class
    inherit PlacementStrategy
[<System.Serializable>]
[<Orleans.GenerateSerializer>]
[<Orleans.Immutable>]
[<Orleans.SuppressReferenceTracking>]
type PreferLocalPlacement = class
    inherit PlacementStrategy
Public Class PreferLocalPlacement
Inherits PlacementStrategy
Public NotInheritable Class PreferLocalPlacement
Inherits PlacementStrategy
Inheritance
PreferLocalPlacement
Attributes

Remarks

If the host is not compatible with the grain type or if a grain receives an incompatible request, the grain will be placed on a random, compatible server.

Constructors

PreferLocalPlacement()

Properties

IsUsingGrainDirectory

Gets a value indicating whether or not this placement strategy requires activations to be registered in the grain directory.

(Inherited from PlacementStrategy)

Methods

Initialize(GrainProperties)

Initializes an instance of this type using the provided grain properties.

(Inherited from PlacementStrategy)
PopulateGrainProperties(IServiceProvider, Type, GrainType, Dictionary<String,String>)

Populates grain properties to specify the preferred placement strategy.

(Inherited from PlacementStrategy)

Applies to