# PreferLocalPlacement

Package: [Microsoft.Orleans.Core.Abstractions](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/) 10.0.0

[NuGet package](https://www.nuget.org/packages/Microsoft.Orleans.Core.Abstractions) | [Source](https://github.com/dotnet/orleans/blob/e4e752cedecc2976811db49802c7a999b1f1c704/src/Orleans.Core.Abstractions/Placement/PreferLocalPlacement.cs#L14)

```csharp
[Orleans.GenerateSerializer]
[Orleans.Immutable]
[Orleans.SuppressReferenceTracking]
public sealed class PreferLocalPlacement : PlacementStrategy
```

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.

## 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](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/orleans.runtime.preferlocalplacement/constructors/constructor-067dde01/)
