[akka-user] Remote deployment PropsData design?

2014-03-17 Thread Roger Alsing
This is related to my first question regarding remote deployment protobuf message. The DaemonMsgCreateData has a PropsData, which in turn holds a list of args that is needed in order to create the actor instance on the remote node. This is accomplished using two repeated fields, "args" and "cla

Re: [akka-user] Distributed transactions in Akka

2014-03-13 Thread Roger Alsing
Should we stop thinking about transactions as something binary and instant, that either succeeds or fails here and now? And instead reason about this more as real world processes, where a transaction can be very long running. e.g. if I send an invoice to a customer and they don't pay, I need to s

[akka-user] Remote deployment not carrying over Props.Mailbox nor Deploy.Mailbox ?

2014-03-09 Thread Roger Alsing
I've noticed that in the DaemonMsgCreateSerializer, mailbox settings are not carried over to the remote system, why is that? The DaemonMsgCreate does have a Props and a Deploy field, but those protobuf messages does not include Mailbox settings. Thus. If I do Props.withMailbox(..).withDeploy(..

Re: [akka-user] FSM and multiple parallell states in the same entity

2014-02-27 Thread Roger Alsing
e additional > tools available first - which we are working on right now. > > -Endre > > > On Thu, Feb 27, 2014 at 8:57 AM, Roger Alsing > > wrote: > >> Ok, thanks. >> I recently had an usecase like this so I got curious to how it would be >> done with A

[akka-user] Re: Event Sourcing and Versioning

2014-02-27 Thread Roger Alsing
There is a quite nice approach that Rickard Öberg uses for Qi4J. He uses _two_ versions for each message. "old" and "new" old events needs to be able to be promoted to new events. so each time you deploy, you promote old messages to new messages, and the system will run with only the new version.

Re: [akka-user] FSM and multiple parallell states in the same entity

2014-02-26 Thread Roger Alsing
Harel state machines, but that is a challenge to get right > and efficient; so far nobody has picked up the challenge (and the core team > is busy doing other things). > > Regards, > > Roland > > 26 feb 2014 kl. 13:55 skrev Roger Alsing > >: > > I'm not followi

Re: [akka-user] FSM and multiple parallell states in the same entity

2014-02-26 Thread Roger Alsing
) when(blue -> pink) Den onsdagen den 26:e februari 2014 kl. 13:34:28 UTC+1 skrev √: > You make the state of the actor a datatype which holds the different > states? > > > On Wed, Feb 26, 2014 at 12:38 PM, Roger Alsing > > > wrote: > >> How do you

Re: [akka-user] FSM and multiple parallell states in the same entity

2014-02-26 Thread Roger Alsing
> You make the state of the actor a datatype which holds the different > states? > > > On Wed, Feb 26, 2014 at 12:38 PM, Roger Alsing > > > wrote: > >> How do you deal with actors/entities that have multiple states in >> parallell? >> The FSM acto

[akka-user] FSM and multiple parallell states in the same entity

2014-02-26 Thread Roger Alsing
How do you deal with actors/entities that have multiple states in parallell? The FSM actors only have one set of states that it transitions in, afaik But what if you have two or more set of states? Set 1: State 1, State 2, State 3 Set 2: State A, State B, State C Where the both set of state

[akka-user] Some Akka API design decision questions

2014-02-21 Thread Roger Alsing
Is there a reason why there is no WithSupervisorStrategy on Props? ( Is it because Scala can override the supervisorStrategy method inline when using actorOf? Or are there other ways to reuse a supervisorstrategy for multiple actors? And when adding routees to a router, there was a now depricated

[akka-user] debug.receive = on for UntypedActor/java

2014-02-20 Thread Roger Alsing
Is there any way to use "debug.receive = on" using the Java API? I see that the scala API wraps the receive function but how does Java does it with its OnRecive method? //Roger -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: http://akka.io/faq/ >>

Re: [akka-user] Actor life cycle test question.

2014-02-09 Thread Roger Alsing
Thanks. got it :-) Den söndagen den 9:e februari 2014 kl. 16:21:10 UTC+1 skrev rkuhn: > > Hi Roger, > > 9 feb 2014 kl. 10:57 skrev Roger Alsing > >: > > I've ported the following test to .NET > > https://github.com/akka/akka/blob/master/akka-ac

[akka-user] Actor life cycle test question.

2014-02-09 Thread Roger Alsing
I've ported the following test to .NET https://github.com/akka/akka/blob/master/akka-actor-tests/src/test/scala/akka/actor/ActorLifeCycleSpec.scala However, there is one thing I don't get with this implementation. On line 28. def receive = { case "status" ⇒ sender() ! message("OK") } The LifeCyc

[akka-user] Re: Occasionally active actors

2014-02-06 Thread Roger Alsing
to shutdown. >>> } >>> } >>> case InactiveActorTimerMsg(Id) => { >>> // Timer for this actor has hit. It's been inactive for too long. >>> Send a msg to the actor to serialize itself and shut itself down. >>> a

[akka-user] Occasionally active actors

2014-02-04 Thread Roger Alsing
Lets say we have the following senario * we have an unbounded number of entities * each entity may only process one command at a time * each entity only process a few messages occasionally and then idle for an undefined amount of time Spawning an actor for each entity would force us to keep atle

Re: [akka-user] Automatic remote 'sender' reference management

2014-01-27 Thread Roger Alsing
Yes, thanks, I figured it out, a bit much to take in sometimes but I've got the remote stuff working now :-) Den måndagen den 27:e januari 2014 kl. 13:21:54 UTC+1 skrev Akka Team: > > Hi Roger, > > Can anyone direct me to where I might find more info on this? >> > > Well, not really apart from r

[akka-user] Automatic remote 'sender' reference management

2014-01-26 Thread Roger Alsing
I'm trying to figure out how Akka deals with remote sender. I pretty sure I've read that Akka will open up a remoting server on the client when passing messages to a remote actor, incase I want to reply to the sender. I just can't find where I read that (if I actually did) I've found this secti

Re: [akka-user] Akkas non blocking network IO with protobuff?

2014-01-22 Thread Roger Alsing
between platforms (protobuf, or whatever). > > -Endre > > > On Mon, Jan 20, 2014 at 2:09 PM, Roger Alsing > > wrote: > >> Thanks, >> I've got the protos working in .NET, too bad the binary java serializer >> is used for user message payload, that makes cros

[akka-user] Actor selection wildcard

2014-01-21 Thread Roger Alsing
What is actually matched when using a wildcard such as "*" ? Is it the actors that match the pattern _now_ , or is it the actors that match the pattern _over time_. that is, is it a snapshot of actors at the time when the selection was applied, or does it mean "a concurrent mutating child collec

Re: [akka-user] Akkas non blocking network IO with protobuff?

2014-01-20 Thread Roger Alsing
. 13:57:18 UTC+1 skrev Akka Team: > > Hi Roger, > > > On Mon, Jan 20, 2014 at 1:36 PM, Roger Alsing > > wrote: > >> Thanks :) >> So it's just a 4 bytes prefix for each message? or could one frame >> contain multiple protos? >> > >

Re: [akka-user] Akkas non blocking network IO with protobuff?

2014-01-20 Thread Roger Alsing
FieldFrame encoder to add length information for decoding message > boundaries. > > -Endre > > > On Mon, Jan 20, 2014 at 1:10 PM, Roger Alsing > > wrote: > >> This might be too offtopic for the intention of this forum, but I'll >> shoot anyway. >>

[akka-user] Akkas non blocking network IO with protobuff?

2014-01-20 Thread Roger Alsing
This might be too offtopic for the intention of this forum, but I'll shoot anyway. I've read that the new network implementation is completely non blocking using actors and sockets (if I didn't misunderstand that is..) So how do you deal with deserialization of the protobuf messages? Are they l

[akka-user] How does Akka deal with Zombie processes?

2014-01-17 Thread Roger Alsing
If an actor for some reason goes into spin and never returns. What do Akka do ? I might have missed it but I didn't see any timeout handling for the actual receive method. Is this dealt with by messages from parents/other actors? that can from time to time poll to see if the ref is still alive? D

[akka-user] Re: Process mailbox at faster rate

2014-01-17 Thread Roger Alsing
I assume you could also include a version/retry number in the message and response to and from the other actors. so that when you receive messages you know if you should increase the reply count. "A" knows what version/rety it is on right now, and should only care abour replies originating from

Re: [akka-user] Reason why ForkJoinPool scales well with Akka?

2014-01-15 Thread Roger Alsing
gt; > > wrote: > >> Ouch. >> So what doe Akka muster on your machine with the same-ish type of config? >> >> >> On Wed, Jan 15, 2014 at 11:32 AM, Roger Alsing >> >> > wrote: >> >>> The .NET thread pool does some magic with the t

Re: [akka-user] Reason why ForkJoinPool scales well with Akka?

2014-01-15 Thread Roger Alsing
t;>So if you only use 4 OS-threads in your ThreadPool, and use 8 actors, you get ~4779000? Yes Den onsdagen den 15:e januari 2014 kl. 11:20:12 UTC+1 skrev √: > > > > > On Wed, Jan 15, 2014 at 11:16 AM, Roger Alsing > > > wrote: > >> On my machine I get the be

Re: [akka-user] Reason why ForkJoinPool scales well with Akka?

2014-01-15 Thread Roger Alsing
messages/s Den onsdagen den 15:e januari 2014 kl. 10:54:25 UTC+1 skrev √: > > > > > On Wed, Jan 15, 2014 at 10:40 AM, Roger Alsing > > > wrote: > >> I couldn't find much else than that the Java ThreadPool does >> locking/blocking when scheduling, I guess

Re: [akka-user] Reason why ForkJoinPool scales well with Akka?

2014-01-15 Thread Roger Alsing
fork join implementation (?) Den måndagen den 13:e januari 2014 kl. 13:01:02 UTC+1 skrev √: > > > > > On Mon, Jan 13, 2014 at 11:52 AM, Roger Alsing > > > wrote: > >> I'm trying to understand why the fork join pool scales better than the >> threa

[akka-user] Reason why ForkJoinPool scales well with Akka?

2014-01-13 Thread Roger Alsing
I'm trying to understand why the fork join pool scales better than the thread pool. My understanding is that FJP can partition tasks into subtasks to optimize the work done on the underlying threads. How does this affect the mailboxes in Akka? Since a given mailbox can only process one message a

Re: [akka-user] actorRef.tell(message) sender?

2014-01-13 Thread Roger Alsing
ngel "Java" Lopez > @ajlopez > > > > On Wed, Jan 1, 2014 at 12:51 AM, √iktor Ҡlang > > > wrote: > >> Inside an Actor, the self-reference is implicit. Since the sender >> argument is implicit then implicit resolution takes place before a def

[akka-user] Legal/Licensing question - Porting

2014-01-10 Thread Roger Alsing
I just want to check with you guys so I don't start to do things I'm not allowed to do here. I'm making a .NET port of Akka Actors, how close to the java/scala implementation am I allowed to go? I know it is apache 2 licensed, but I want to make sure I don't go too far here. e.g. can I re-use

Re: [akka-user] Congestion in Supervisor?

2014-01-07 Thread Roger Alsing
; >> >> >> >> Den tisdagen den 7:e januari 2014 kl. 11:43:13 UTC+1 skrev drewhk: >>> >>> Hi Roger, >>> >>> I am also a bit unsure about the question, but system messages (the >>> messages used by supervision for example) are

Re: [akka-user] Congestion in Supervisor?

2014-01-07 Thread Roger Alsing
n Tue, Jan 7, 2014 at 11:06 AM, √iktor Ҡlang > > > wrote: > >> Not sure I follow, can you create a code sample in Akka that shows the >> perceived problem? >> >> >> On Tue, Jan 7, 2014 at 8:45 AM, Roger Alsing >> > wrote: >> >>>

[akka-user] Congestion in Supervisor?

2014-01-06 Thread Roger Alsing
How does the supervisor deal with congestion? Lets say that Actor A sends all it's incoming messages to child Actor B. And lets say we pass 1000 messages to actor A, then actor B will eventually also get 1000 messages. But if B for some reason throws, e.g. on each message, then actor B will thro

[akka-user] Akka protocols?

2014-01-02 Thread Roger Alsing
Is there any good place to read about the protocols used by Akka when communicating between nodes? I'm making a .NET port of Akka Actors just for the hell of it, and it would be quite nice if I could integrate with real Akka nodes. -- >> Read the docs: http://akka.io/docs/ >>>

Re: [akka-user] actorRef.tell(message) sender?

2014-01-02 Thread Roger Alsing
Ah, thanks :) Den onsdagen den 1:e januari 2014 kl. 04:51:40 UTC+1 skrev √: > > Inside an Actor, the self-reference is implicit. Since the sender argument > is implicit then implicit resolution takes place before a default value is > applied. > > Cheers, > V > On Jan

[akka-user] actorRef.tell(message) sender?

2013-12-31 Thread Roger Alsing
According to the documentation, tell with only a message arg will be called with "this" as sender: other.tell(msg); // uses this actor as sender reference, reply goes to us Is this really the case? When I look at the source for actorRef.scala , the default value used is "actorRef

[akka-user] ActorContext

2013-12-30 Thread Roger Alsing
How is the ActorContext attached to the Actors ? I'm from the .NET world and I'm playing around with my own mini port of Akka (weekend hack so far) What I find strange is that the context is visible to the actors at construction. e.g. fields in an actor can be initialized using something like Ac