Microsoft.Orleans.Serialization 10.0.0

Microsoft Orleans Serialization

Introduction

Microsoft Orleans Serialization is a fast, flexible, and version-tolerant serializer for .NET. It provides the core serialization capabilities for Orleans, enabling efficient serialization and deserialization of data across the network and for storage.

Getting Started

To use this package, install it via NuGet:

dotnet add package Microsoft.Orleans.Serialization

This package is automatically included when you reference the Orleans SDK or the Orleans client/server metapackages.

Example

// Creating a serializer
var services = new ServiceCollection();
services.AddSerializer();
var serviceProvider = services.BuildServiceProvider();
var serializer = serviceProvider.GetRequiredService<Serializer>();

// Serializing an object
var bytes = serializer.SerializeToArray(myObject);

// Deserializing an object
var deserializedObject = serializer.Deserialize<MyType>(bytes);

Supporting your own Types

To make your types serializable in Orleans, mark them with the [GenerateSerializer] attribute and mark each field/property which should be serialized with the [Id(int)] attribute:

[GenerateSerializer]
public class MyClass
{
    [Id(0)]
    public string Name { get; set; }
    
    [Id(1)]
    public int Value { get; set; }
}

Documentation

For more comprehensive documentation, please refer to:

Feedback & Contributing

Showing the top 20 packages that depend on Microsoft.Orleans.Serialization.

Packages Downloads
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
22
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
20
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
18
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
17
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
16
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
15
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
14
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
12
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
11

.NET 8.0

.NET 10.0

.NET Standard 2.1

Version Downloads Last updated
10.0.0 3 1/26/2026
10.0.0-rc.2 3 1/4/2026
9.2.1 8 7/26/2025
9.2.0 10 7/27/2025
9.2.0-preview3 4 6/17/2025
9.2.0-preview2 2 6/9/2025
9.2.0-preview1 19 6/10/2025
9.1.2 19 6/10/2025
9.0.1 10 6/10/2025
9.0.0 20 6/10/2025
8.2.0 12 6/10/2025
8.2.0-preview1 18 6/10/2025
8.1.0 11 6/8/2025
8.1.0-preview3 19 6/10/2025
8.1.0-preview2 11 6/10/2025
8.1.0-preview1 17 6/10/2025
8.0.0 20 6/10/2025
8.0.0-rc2 16 6/10/2025
8.0.0-rc1 20 6/10/2025
7.2.7 18 6/10/2025
7.2.6 19 6/10/2025
7.2.5 10 6/10/2025
7.2.4 17 6/10/2025
7.2.3 19 6/10/2025
7.2.2 19 6/10/2025
7.2.1 12 6/10/2025
7.2.0 16 6/10/2025
7.1.2 17 6/10/2025
7.1.1 20 6/10/2025
7.1.0 19 6/10/2025
7.0.0 16 6/10/2025
7.0.0-rc2 42 6/10/2025
4.0.0-preview2 19 6/10/2025
4.0.0-preview1 17 6/10/2025