Microsoft.Orleans.Clustering.AzureStorage 9.2.0-preview3

Prefix Reserved
This is a prerelease version of Microsoft.Orleans.Clustering.AzureStorage.
There is a newer version of this package available.
See the version list below for details.
dotnet add package Microsoft.Orleans.Clustering.AzureStorage --version 9.2.0-preview3
                    
NuGet\Install-Package Microsoft.Orleans.Clustering.AzureStorage -Version 9.2.0-preview3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Microsoft.Orleans.Clustering.AzureStorage" Version="9.2.0-preview3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Microsoft.Orleans.Clustering.AzureStorage" Version="9.2.0-preview3" />
                    
Directory.Packages.props
<PackageReference Include="Microsoft.Orleans.Clustering.AzureStorage" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Microsoft.Orleans.Clustering.AzureStorage --version 9.2.0-preview3
                    
#r "nuget: Microsoft.Orleans.Clustering.AzureStorage, 9.2.0-preview3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Microsoft.Orleans.Clustering.AzureStorage@9.2.0-preview3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Microsoft.Orleans.Clustering.AzureStorage&version=9.2.0-preview3&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Microsoft.Orleans.Clustering.AzureStorage&version=9.2.0-preview3&prerelease
                    
Install as a Cake Tool

Microsoft Orleans Clustering Provider for Azure Storage

Introduction

Microsoft Orleans Clustering Provider for Azure Storage allows Orleans silos to organize themselves as a cluster using Azure Table Storage. This provider enables silos to discover each other, maintain cluster membership, and detect and handle failures.

Getting Started

To use this package, install it via NuGet:

dotnet add package Microsoft.Orleans.Clustering.AzureStorage

Example - Configuring Azure Storage Clustering

using Microsoft.Extensions.Hosting;
using Orleans.Configuration;
using Orleans.Hosting;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Threading.Tasks;

// Define a grain interface
public interface IHelloGrain : IGrainWithStringKey
{
    Task<string> SayHello(string greeting);
}

// Implement the grain interface
public class HelloGrain : Grain, IHelloGrain
{
    public Task<string> SayHello(string greeting)
    {
        return Task.FromResult($"Hello, {greeting}!");
    }
}

var builder = Host.CreateApplicationBuilder(args)
    .UseOrleans(siloBuilder =>
    {
        siloBuilder
            // Configure Azure Table Storage for clustering
            .UseAzureStorageClustering(options =>
            {
                options.ConnectionString = "YOUR_AZURE_STORAGE_CONNECTION_STRING";
                options.TableName = "OrleansClustering"; // Optional: defaults to "OrleansClustering"
            });
    });

var host = builder.Build();
await host.StartAsync();

// Get a reference to a grain and call it
var client = host.Services.GetRequiredService<IClusterClient>();
var grain = client.GetGrain<IHelloGrain>("user123");
var response = await grain.SayHello("World");

// Print the result
Console.WriteLine($"Grain response: {response}");

// Keep the host running until the application is shut down
await host.WaitForShutdownAsync();

Example - Configuring Client to Connect to Cluster

using Microsoft.Extensions.Hosting;
using Orleans;
using Orleans.Configuration;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Threading.Tasks;
namespace ExampleGrains;

// Define a grain interface
public interface IHelloGrain : IGrainWithStringKey
{
    Task<string> SayHello(string greeting);
}

var clientBuilder = Host.CreateApplicationBuilder(args)
    .UseOrleansClient(clientBuilder =>
    {
        clientBuilder
            // Configure the client to use Azure Storage for clustering
            .UseAzureStorageClustering(options =>
            {
                options.ConnectionString = "YOUR_AZURE_STORAGE_CONNECTION_STRING";
                options.TableName = "OrleansClustering"; // Optional: defaults to "OrleansClustering"
            });
    });

var host = clientBuilder.Build();
await host.StartAsync();
var client = host.Services.GetRequiredService<IClusterClient>();

// Get a reference to a grain and call it
var grain = client.GetGrain<IHelloGrain>("user123");
var response = await grain.SayHello("World");

// Print the result
Console.WriteLine($"Grain response: {response}");

// Keep the host running until the application is shut down
await host.WaitForShutdownAsync();

Documentation

For more comprehensive documentation, please refer to:

Feedback & Contributing

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (9)

Showing the top 5 NuGet packages that depend on Microsoft.Orleans.Clustering.AzureStorage:

Package Downloads
Blauhaus.Orleans

Package Description

Blauhaus.EVACS.Orleans

Package Description

Aksio.Cratis.Extensions.Orleans

Package Description

Microsoft.Orleans.OrleansAzureUtils

Support library for hosting Orleans on Microsoft Azure.

Aksio.Cratis.Kernel.Orleans

Package Description

GitHub repositories (8)

Showing the top 8 popular GitHub repositories that depend on Microsoft.Orleans.Clustering.AzureStorage:

Repository Stars
dotnet/aspire
Tools, templates, and packages to accelerate building observable, production-ready apps
Dotnet-Boxed/Templates
.NET project templates with batteries included, providing the minimum amount of code required to get you going faster.
microsoft/dotnet-podcasts
.NET reference application shown at .NET Conf featuring ASP.NET Core, Blazor, .NET MAUI, Microservices, Orleans, Playwright, and more!
dotnet/dotnet
Home of .NET's Virtual Monolithic Repository which includes all the code needed to build the .NET SDK.
axzxs2001/Asp.NetCoreExperiment
原来所有项目都移动到**OleVersion**目录下进行保留。新的案例装以.net 5.0为主,一部分对以前案例进行升级,一部分将以前的工作经验总结出来,以供大家参考!
Samsung/Tizen.NET
Welcome to Tizen .NET
J-Tech-Japan/Sekiban
Sekiban - an Opinionated Event Sourcing and CQRS Framework using C#. It can store data into Azure Cosmos DB, AWS Dynamo DB or Postgres
ReubenBond/hanbaobao-web
Orleans sample application with Kubernetes hosting
Version Downloads Last Updated
9.2.1 17,447 7/16/2025
9.2.0 567 7/14/2025
9.2.0-preview3 732 6/10/2025
9.2.0-preview2 169 6/4/2025
9.2.0-preview1 5,936 4/4/2025
9.1.2 122,383 2/13/2025
9.0.1 44,135 11/23/2024
9.0.0 4,840 11/14/2024
8.2.0 182,810 7/12/2024
8.2.0-preview1 328 5/22/2024
8.1.0 133,377 4/17/2024
8.1.0-preview3 1,550 3/11/2024
8.1.0-preview2 221 2/23/2024
8.1.0-preview1 1,324 2/13/2024
8.0.0 62,278 1/5/2024
8.0.0-rc2 323 12/20/2023
8.0.0-rc1 372 12/4/2023
7.2.7 1,142 10/15/2024
7.2.6 25,083 3/9/2024
7.2.5 6,223 2/22/2024
7.2.4 107,962 12/2/2023
7.2.3 21,024 11/3/2023
7.2.2 10,038 10/16/2023
7.2.1 98,567 7/11/2023
7.2.0 5,720 7/7/2023
7.1.2 57,514 4/19/2023
7.1.1 60,799 3/23/2023
7.1.0 88,476 2/1/2023
7.0.0 32,694 11/8/2022
7.0.0-rc2 422 10/19/2022
4.0.0-preview2 11,492 8/4/2022
4.0.0-preview1 4,617 2/10/2022
3.8.0 632 5/6/2025
3.8.0-preview5 270 5/12/2025
3.8.0-preview3 235 4/8/2025
3.8.0-preview2 176 4/4/2025
3.8.0-preview1 224 3/31/2025
3.7.2 22,975 5/10/2024
3.7.1 64,052 5/27/2023
3.7.0 66,263 3/23/2023
3.6.5 1,006,126 8/15/2022
3.6.4 19,211 8/10/2022
3.6.3 39,136 8/4/2022
3.6.2 592,561 4/15/2022
3.6.1 272,125 4/5/2022
3.6.0 232,070 1/20/2022
3.5.1 141,540 11/8/2021
3.5.0 108,889 9/3/2021
3.4.4 3,024 10/4/2021
3.4.3 113,458 6/3/2021
3.4.2 57,212 4/5/2021
3.4.1 63,987 2/3/2021
3.4.0 25,950 1/6/2021
3.4.0-rc1 795 12/9/2020
3.3.0 60,811 9/9/2020
3.3.0-rc2 1,835 9/2/2020
3.3.0-rc1 716 8/19/2020
3.2.2 14,479 7/22/2020
3.2.1 7,970 7/2/2020
3.2.0 10,048 6/4/2020
3.2.0-rc2 953 5/20/2020
3.2.0-rc1 988 5/7/2020
3.1.7 9,531 5/19/2020
3.1.6 23,634 4/16/2020
3.1.5 1,766 4/9/2020
3.1.4 20,872 3/26/2020
3.1.3 8,061 3/16/2020
3.1.2 5,934 3/5/2020
3.1.0 4,921 2/23/2020
3.1.0-rc3 867 2/13/2020
3.1.0-rc2 870 2/12/2020
3.1.0-rc1 863 2/10/2020
3.0.2 52,857 12/12/2019
3.0.1 5,590 11/27/2019
3.0.0 6,488 10/24/2019
3.0.0-rc2 1,030 10/16/2019
3.0.0-rc1 877 10/9/2019
3.0.0-beta1 1,343 8/16/2019
2.4.5 12,748 12/29/2019
2.4.4 12,897 11/27/2019
2.4.3 14,493 10/10/2019
2.4.2 13,191 8/31/2019
2.4.1 5,835 8/14/2019
2.4.0 6,687 8/8/2019
2.3.6 26,725 7/24/2019
2.3.5 25,149 6/14/2019
2.3.4 138,271 6/4/2019
2.3.3 2,953 6/2/2019
2.3.2 5,205 5/9/2019
2.3.1 3,938 4/26/2019
2.3.0 45,652 3/20/2019
2.3.0-rc2 2,208 3/13/2019
2.3.0-rc1 2,101 3/4/2019
2.2.4 5,144 2/25/2019
2.2.3 5,011 1/17/2019
2.2.0 15,259 12/13/2018
2.2.0-rc1 2,468 12/4/2018
2.2.0-beta1 2,809 10/21/2018
2.1.2 114,719 10/11/2018
2.1.0 5,091 9/28/2018
2.1.0-rc2 2,804 9/21/2018
2.1.0-rc1 2,888 9/14/2018
2.1.0-beta1 7,841 8/27/2018
2.0.0 91,031 3/28/2018
2.0.0-rc2 6,750 3/13/2018
2.0.0-rc1 7,140 2/26/2018
2.0.0-beta3 4,840 12/21/2017
2.0.0-beta2 2,932 12/11/2017