Microsoft.Orleans.Serialization 9.2.0-preview2
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
- If you have any issues or would like to provide feedback, please open an issue on GitHub
- Join our community on Discord
- Follow the @msftorleans Twitter account for Orleans announcements
- Contributions are welcome! Please review our contribution guidelines
- This project is licensed under the MIT license
Showing the top 20 packages that depend on Microsoft.Orleans.Serialization.
Packages | Downloads |
---|---|
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
|
14 |
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
|
13 |
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
|
12 |
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
|
11 |
Microsoft.Orleans.Core.Abstractions
Core abstractions library of Microsoft Orleans
|
10 |
.NET 8.0
- Microsoft.Orleans.Analyzers (>= 9.2.0-preview2)
- System.IO.Pipelines (>= 8.0.0)
- System.Collections.Immutable (>= 8.0.0)
- Microsoft.CodeAnalysis.Analyzers (>= 3.11.0)
- System.IO.Hashing (>= 8.0.0)
- Microsoft.Extensions.Options (>= 8.0.2)
- Microsoft.Extensions.ObjectPool (>= 8.0.11)
- Microsoft.Extensions.DependencyModel (>= 8.0.2)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 8.0.2)
- Microsoft.CodeAnalysis.Workspaces.Common (>= 4.5.0)
- Microsoft.CodeAnalysis.Common (>= 4.5.0)
- Microsoft.Orleans.Serialization.Abstractions (>= 9.2.0-preview2)
- Microsoft.Orleans.CodeGenerator (>= 9.2.0-preview2)
.NET Standard 2.1
- System.Text.Json (>= 8.0.5)
- System.IO.Pipelines (>= 8.0.0)
- Microsoft.CodeAnalysis.Analyzers (>= 3.11.0)
- System.IO.Hashing (>= 8.0.0)
- System.Collections.Immutable (>= 8.0.0)
- Microsoft.Extensions.Options (>= 8.0.2)
- Microsoft.Extensions.ObjectPool (>= 8.0.11)
- Microsoft.Extensions.DependencyModel (>= 8.0.2)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 8.0.2)
- Microsoft.DotNet.PlatformAbstractions (>= 3.1.6)
- Microsoft.CodeAnalysis.Workspaces.Common (>= 4.5.0)
- Microsoft.CodeAnalysis.Common (>= 4.5.0)
- Microsoft.Orleans.CodeGenerator (>= 9.2.0-preview2)
- Microsoft.Orleans.Serialization.Abstractions (>= 9.2.0-preview2)
- Microsoft.Orleans.Analyzers (>= 9.2.0-preview2)
Version | Downloads | Last updated |
---|---|---|
9.2.0-preview3 | 2 | 06/14/2025 |
9.2.0-preview2 | 2 | 06/08/2025 |
9.2.0-preview1 | 7 | 04/14/2025 |
9.1.2 | 10 | 02/21/2025 |
9.1.0 | 3 | 05/12/2025 |
9.0.1 | 14 | 11/25/2024 |
9.0.0 | 9 | 11/25/2024 |
8.2.0 | 14 | 10/06/2024 |
8.2.0-preview1 | 9 | 10/09/2024 |
8.1.0 | 14 | 10/09/2024 |
8.1.0-preview3 | 12 | 10/09/2024 |
8.1.0-preview2 | 12 | 10/09/2024 |
8.1.0-preview1 | 12 | 10/09/2024 |
8.0.0 | 15 | 10/09/2024 |
8.0.0-rc2 | 9 | 10/09/2024 |
8.0.0-rc1 | 10 | 10/09/2024 |
7.2.7 | 13 | 11/25/2024 |
7.2.6 | 9 | 10/09/2024 |
7.2.5 | 13 | 10/09/2024 |
7.2.4 | 12 | 10/09/2024 |
7.2.3 | 9 | 10/09/2024 |
7.2.2 | 11 | 10/09/2024 |
7.2.1 | 14 | 10/09/2024 |
7.2.0 | 13 | 10/09/2024 |
7.1.2 | 10 | 10/09/2024 |
7.1.1 | 14 | 10/09/2024 |
7.1.0 | 13 | 10/09/2024 |
7.0.0 | 14 | 10/09/2024 |
7.0.0-rc2 | 13 | 10/09/2024 |
4.0.0-preview2 | 11 | 10/09/2024 |
4.0.0-preview1 | 14 | 10/09/2024 |