Orleankka
Orleankka is a functional API for Microsoft Orleans framework. It is highly suitable for scenarios where having composable, uniform communication interface is preferable, such as: CQRS, event-sourcing, re-routing, FSM, etc.
Orleankka is not just a translation layer on top of Orleans. Besides improved language support, Orleannka brings several new important features and fixes a lot of small-to-medium annoyances, constraints and some of the major limitations, currently present in Orleans' programming model.
References: video, slides and discussion.
Features
Runtime
- Pluggable serialization protocols
- Dependency injection support
- Simplified configuration via fluent DSL (client, cluster, azure, embedded)
- Programmable from any .NET language
Actors
- Typed actors for strong type-safety and IntelliSense support
- Message interception via higher-order catch-all function (AOP)
- Automatic GC with configurable keep-alive timeouts
- Runtime independence (isolated testing)
- Reentrant messages
- Special api for F# (DU, Pattern Matching, Tasks, Custom DSL)
Streams
- Greatly simplified and more convenient api (actor subscriptions)
- Declarative regex-based subscriptions (great for CQRS/ES projections)
- Content-based filtering with static functions (both imperative and declarative)
- Support of all built-in and custom stream providers
Other
- Convenient unit testing kit (stubs, mocks, expectations)
- Push-based notifications with observers
- Reactive Extensions (RX) support (client-side observers only)
- Improved exception handling
How to install
To install Orleankka via NuGet, run this command in NuGet package manager console:
PM> Install-Package Orleankka
Check out "Getting started" guide (F#).
Add-ons
[inside] | ||
---|---|---|
Orleankka.FSharp | Special api for F# | |
Orleankka.TestKit | Unit testing kit | |
Orleankka.Azure | Fluent configuration for Azure |
Examples
C#
- "WebScan" [demo]
- TestKit [demo]
- Event Sourcing
- Reentrant messages [rw-x]
- Azure cloud service [hub]
- Client-side observers [chat]
- Streams [chat]
F#
Serialization
- .NET binary [default]
- Orleans native (codegened) [built-in]
- Newtonsoft.JSON [see]
Dependency Injection
Documentation
Complete documentation could be found on wiki.
Known issues
Integration tests (those using real actor system) won't work with XUnit visual studio runner due to inability to disable shadow copy xunit/visualstudio.xunit#9
Contributing
Any bug-fix pull request goes without a saying. For new features or modifications, please first create an issue, so we can discuss it before any effort is made. Add-ons, like new serialization or communication protocols, DI container support, FSM, etc - are highly welcomed!
Community
License
Apache 2 License