GithubHelp home page GithubHelp logo

akkadotnet / akka.net Goto Github PK

View Code? Open in Web Editor NEW
4.6K 258.0 1.0K 88.66 MB

Canonical actor model implementation for .NET with local + distributed actors in C# and F#.

Home Page: http://getakka.net

License: Other

F# 0.58% C# 99.34% Shell 0.03% Batchfile 0.01% PowerShell 0.05% Dockerfile 0.01%
akka actor-model dotnet concurrency cluster actor reactive distributed-programming hacktoberfest c-sharp

akka.net's People

Contributors

aaronontheweb avatar alexvaluyskiy avatar annymsmthd avatar arkatufus avatar brah-mcdude avatar cconstantin avatar danthar avatar dependabot-preview[bot] avatar dependabot[bot] avatar eaba avatar f0b0s avatar fergusn avatar hcanber avatar heynickc avatar horusiath avatar igorfedchenko avatar ismaelhamed avatar jdsartori avatar jeffcyr avatar kekekeks avatar marcpiechura avatar rogeralsing avatar sean-gilliam avatar seankilleen avatar simoncropp avatar smalldave avatar stefansedich avatar thinkbeforecoding avatar zbynek001 avatar zetanova avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

akka.net's Issues

Add log/debug functionallity

The ActorSystem.Settings class contains a few settings related to logging in various conditions.
These should be used to trigger logging.
See real Akka code for each of those Settings prop

Rewrite ActorSelection

Actor selection is not implemented correctly.
Akka uses an ActorSelection type with an "Anchor" actorref and a list of string elements describing the navigation/selection.
The resolution is done lazily and not directly.

LocalActorRef.Stop() and Context.Stop(ActorRef) yield different results for child actors

When attempting to stop a child Actor, there are a couple of different methods of doing it.

Calling LocalActorRef.Stop() on the child's ActorRef doesn't end the parent actor's supervision of the child, but Context.Stop(ActorRef) does - need to implement some messaging to tell the parent to stop watching the child regardless of how it died, so long as it was gracefully terminated.

Add Serialize all messages/creators

http://doc.akka.io/docs/akka/2.0.1/scala/serialization.html

""""
Verification
If you want to verify that your messages are serializable you can enable the following config option:

val config = ConfigFactory.parseString("""
akka {
actor {
serialize-messages = on
}
}
""")

When a call to ActorRef.Post occurs, the passed message needs to be serialized and then deserialized directly before put on the mailbox queue.

This feature is to ensure that your messages are immutable,(in test environments) not passing mutable data around.

There is a setting for this in the ActorSystem.Settings

Make ActorRef serializable in messages

ActorRef's can currently only be passed to remote systems via sender and recipient.
If a message contains an actorref, it will fail.
ActorRefs needs to be serializable.

Note, each kind of actorref needs to be serializable, LocalActorRef, RemoteActorRef etc.
I guess needs custom code for each kind of serializer (?) since each ref is context bound, it only means something within the context of a system.

Extend Ask support

We should extend the ask support to allow passing a timeout param (Timespan and milliseconds)
We should also allow asking for a specific type.

Add custom TaskScheduler for async await operations within an actor

If one add async code within an actor, e.g an "await" call.
We can not currently guarantee that the actor executes within its concurrency boundarys.
the only way to do this is to marshall a TaskCompletionSource through the actors mailbox and thus force the completion to be set within the actors message handler.

So for the ask support, this works, we do this in ActorRef.Ask(object message)

However, if we do e.g. async IO or any other async await from within an actor, this will not be guaranteed.

I beleive this is possible to resolve by writing a custom task scheduler or whatever it is called, and I'm pretty sure I saw one in Helios(?) cc. @Aaronontheweb

Thoughts?

Idea: Actor cluster

@rogeralsing separate from the notion of clustering Akka servers, I had an idea for combining Routing and Broadcast Actors into a suite designed for bursty workloads.

An Actor cluster: essentially it's a router that can have new Actors join and previous Actors leave when doing processing. For instance, during peak loads I might need 100+ database request-handler Actors per machine, but only 5-10 during regular loads.

The Actor cluster is itself an Actor, and it implements a built-in Router. it can receive special messages to create new Actors under its management and if a child actor terminates then it leaves the cluster.

I've built something like this into my own user code - does this seem like something worth including in the framework itself or is it too domain-specific?

Mono support

We need to ensure that Akka.NET works on mono.

Add Consistent Hashing router support

http://doc.akka.io/api/akka/snapshot/index.html#akka.routing.ConsistentHashingRouter

There is 3 ways to define what data to use for the consistent hash key.

  1. You can define hashMapping / withHashMapper of the router to map incoming messages to their consistent hash key. This makes the decision transparent for the sender.
  2. The messages may implement akka.routing.ConsistentHashingRouter.ConsistentHashable. The key is part of the message and it's convenient to define it together with the message definition.
  3. The messages can be be wrapped in a akka.routing.ConsistentHashingRouter.ConsistentHashableEnvelope to define what data to use for the consistent hash key. The sender knows the key to use.

RemoteDeploy\Shared\Shared.csproj missing

Just ran into the following issue when making a NuGet build:

Build FAILED.

"D:\Repositories\Pigeon\Pigeon.sln" (Clean;Build target) (1) ->
(Clean target) ->
  D:\Repositories\Pigeon\Pigeon.sln.metaproj : error MSB3202: The project file "D:\Repositories\Pigeon\Examples\RemoteD
eploy\Shared\Shared.csproj" was not found. [D:\Repositories\Pigeon\Pigeon.sln]

    0 Warning(s)
    1 Error(s)

Looks like there's a missing .csproj file from the repository - could we add this?

Move to an organization?

I've noticed that community projects under an appropriate organization (e.g. github.com/fsprojects) seem to get more contributors and a sense of mutual contribution/ownership.

So I'm wondering whether this project could move to an akkanet organization? Or perhaps start a "dotnetprojects" community space akin to the "fsprojects" space - which has proved very successful at bringing F# community projects together?

Just an idea, you may have plans like this in any case.

Add RemoteDaemon

The remote daemon is responsible for creatng new actors on request from a remote system.

In real Akka, this is implemented using a VirtualPathContainer.
This means that when a remote system tells the daemon to create a given actor. it will be created with the path that is requested, but placed under the /remote/* path.

so if system1 requests a new instance of system1/user/foo/bar to be created remotely.
it will be created as system2/remote/foo/bar

Thus, the "remote" actor/daemon needs to be able to create children with paths instead of names.
And those paths should be unrelated also.
system2/remote/foo is not the parent of system2/remote/foo/bar
they both are children of remote

Add ActorRefProvider functionallity

There is currently only one ActorRefProvider, this should be extended to behave as real Akka with a RemoteActorRefProvider.

Currently, remoting is implemented as an extension. this should be changed.
The actor system should pick the setting from the config and apply the correct actor ref provider using this.

Better F# API

Scala uses some special syntax for declaring actors.
We should investigate how an idiomatic F# actor would look using the Pigeon/Akka concepts.

Need to make ActorPath behavior consistent with Akka

Couple of examples from integrating Pigeon today:

Absolute paths should implicitly have /user/ appended to the front
Any absolute path lookup made by a user-defined Actor should implicitly have /user/ appended to the front of it.

For instance, System.ActorSelection("/myrootactor/mychildactor/") is a valid absolute path to the user-defined actor at akka://{system}/user/myrootactor/mychildactor, as indicated by the leading slash.

Need to make it add some utilities to make it easy to define paths
In particular, we need to make it easy to define valid relative Actor paths. Probably can do this inside a simple static class (like PathUtils in Akka) and use it help users make sure their ActorPaths are formatted correctly.

ActorPathSpec

Port the ActorPathSpec to ensure that ActorPath behaves according to the akka spec

Routers

Add support for Akka like Routers

SerializationSpec

Port the SerializationSpec to verify that serialization behaves according to the spec.

EventStreamLogger

@rogeralsing I'd like to be able to expose the logger directly to user Actors - currently I'm having my actors write directly to the event stream and I'm using a specialized Actor to push all of the log messages onto a debug screen for my team using SignalR.

Roger, was planning on adding a System-wide LoggingAdapter that writes directly to the event stream and make that accessible inside the ActorContext but I'm not entirely sure how you're using Logging adapters currently. Is this something you want to make configurable at the ActorSystem level?

Need to decide on an OSS license for Pigeon

In order to use Pigeon in production, we'll need to settle on an acceptable OSS license.

My personal preference is a permissive license like Apache v2, but I'm open to alternatives.

Buffer RemoteActorRef messages

We should add support to buffer messages sent to an RemoteActorRef so that we can pass a single larger message to the remote system instead of multiple single messages.

If the RemoteActorRef has it's own mailbox processor.
We can pull multiple messages from that once it runs.
Put those in a Batch message and pass to the remote system

Integrating Pigeon.Configuration with Web/App.config?

@rogeralsing I'm in the process of integrating Pigeon into a couple of our ASP.NET MVC-based services this week - I'm building an Actor system that is hosted inside an IIS process.

It will accept messages via Remote actors (and I'm going to use that as an opportunity to work on some of the Remote actor issues assigned to me,) but also directly through HTTP requests made to ASP.NET MVC controllers.

This prompted me to ask - going forward, how should we try to reconcile the traditional Web.config model with the Akka-style config model? I can stick my Akka configuration in AppSettings I suppose in the meantime.

We can either keep our configuration model totally separate, or maybe find a happy medium?

Add custom loggers

The LoggerAdapter should be made abstract.
We should provide a few out of the box loggers for Console, Debug, Trace , whatever.
And some external addons for mainstream logging libs.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.