Orleans.FSharp
4.0.2
See the version list below for details.
dotnet add package Orleans.FSharp --version 4.0.2
NuGet\Install-Package Orleans.FSharp -Version 4.0.2
<PackageReference Include="Orleans.FSharp" Version="4.0.2" />
<PackageVersion Include="Orleans.FSharp" Version="4.0.2" />
<PackageReference Include="Orleans.FSharp" />
paket add Orleans.FSharp --version 4.0.2
#r "nuget: Orleans.FSharp, 4.0.2"
#:package Orleans.FSharp@4.0.2
#addin nuget:?package=Orleans.FSharp&version=4.0.2
#tool nuget:?package=Orleans.FSharp&version=4.0.2
Orleans.FSharp
Idiomatic F# computation expressions and helpers for Microsoft Orleans grain development.
Deprecated authoring model. The
grain {}CE and the universalFSharpGrain.*message-passing surface shown below -- builder,GrainDefinition/GrainContext, handles,IFSharpGrain*,ref/send/post/ask,Timers,Reminder-- now carry[<Obsolete>](warning, not error). They keep compiling and running; new code should use the functional grain runtime (grainContract/grainFor/FunctionalGrain.ref/AddFunctionalGrain) described under Functional grain runtime below. Migration guide: docs/functional-grains.md.
What it does
Orleans.FSharp replaces verbose C#-style grain implementations with a declarative grain {} computation expression. Define state, message handlers, persistence, timers, reminders, and streaming in a single expression. Concurrency is controlled per message type with interleaveMessage typeof<'Msg>, and FSharpGrain.post gives true fire-and-forget ([OneWay]) calls.
Modules included
GrainState | GrainRef | GrainBatch | Streaming | BroadcastChannel | Logging | Reminders | Timers | Observers | Filters | RequestCtx | Transactions | Versioning | GrainResilience | Shutdown | StateMigration | Serialization | FSharpSerialization | Scripting | Kubernetes | GrainDirectory | Immutable | StreamProviders
Quick example
open Orleans.FSharp
type CounterMsg = Increment | GetCount
let counterGrain = grain {
defaultState 0
handle (fun state msg -> task {
match msg with
| Increment -> return state + 1, box ()
| GetCount -> return state, box state
})
persist "Default"
}
Related packages
| Package | Purpose |
|---|---|
Orleans.FSharp.Runtime |
Silo and client hosting via siloConfig {} CE |
Orleans.FSharp.CodeGen |
C# bridge for Orleans Roslyn source generators |
Orleans.FSharp.Testing |
Test harness, mocks, and FsCheck integration |
Orleans.FSharp.EventSourcing |
Event-sourced grains via eventSourcedGrain {} CE |
Orleans.FSharp.Analyzers |
F# analyzer detecting async {} usage |
Functional grain runtime
A second, independent authoring model lives alongside the grain {} CE: user-authored API
records (grainContract / grainFor / FunctionalGrain.ref) instead of a CodeGen-generated C#
interface. See Functional Grain Runtime
for key-codec identity rules, operation rename and contract versioning, delivery semantics,
immutable-state guidance, and the reminder rename/removal migration.
Documentation
Full docs and examples: https://github.com/Neftedollar/orleans-fsharp
License
MIT
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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. |
-
net10.0
- FSharp.Control.TaskSeq (>= 0.6.0)
- FSharp.Core (>= 10.1.201)
- FSharp.SystemTextJson (>= 1.4.36)
- FsToolkit.ErrorHandling (>= 5.2.0)
- IcedTasks (>= 0.11.9)
- Microsoft.Extensions.DependencyInjection (>= 10.0.9)
- Microsoft.Extensions.Hosting (>= 10.0.9)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.9)
- Microsoft.Orleans.BroadcastChannel (>= 10.1.0)
- Microsoft.Orleans.Core.Abstractions (>= 10.1.0)
- Microsoft.Orleans.EventSourcing (>= 10.1.0)
- Microsoft.Orleans.Persistence.Memory (>= 10.1.0)
- Microsoft.Orleans.Reminders (>= 10.1.0)
- Microsoft.Orleans.Runtime (>= 10.1.0)
- Microsoft.Orleans.Sdk (>= 10.1.0)
- Microsoft.Orleans.Server (>= 10.1.0)
- Microsoft.Orleans.Streaming (>= 10.1.0)
- Microsoft.Orleans.Transactions (>= 10.1.0)
- Orleans.FSharp.Abstractions (>= 4.0.2)
- Polly (>= 8.7.0)
- TypeShape (>= 10.0.0)
NuGet packages (3)
Showing the top 3 NuGet packages that depend on Orleans.FSharp:
| Package | Downloads |
|---|---|
|
Orleans.FSharp.Runtime
Silo and client hosting for functional Orleans.FSharp actors — registration, serialization, health checks, Dashboard, TLS, and production configuration. |
|
|
Orleans.FSharp.Testing
Test utilities for Orleans.FSharp grains — TestHarness, GrainMock, GrainArbitrary (TypeShape-based FsCheck), FsCheckHelpers, and LogCapture. |
|
|
Orleans.FSharp.EventSourcing
Declarative event sourcing for Orleans grains in F# — eventSourcedGrain {} CE with apply/handle and a JournaledGrain bridge. |
GitHub repositories
This package is not used by any popular GitHub repositories.