Re: [akka-user] mixing FSM and akka-persistence

2014-05-12 Thread christian . kitzmueller
Hi, I think I stumbled over a potential pitfall when using a Processor with a FSM - in case I have a RecoveryFailure the FSM will handle the message via default handling. If I have read the code correctly, the Processor will stay in a state where it stashes incoming messages forever - which

Re: [akka-user] mixing FSM and akka-persistence

2014-05-12 Thread Björn Antonsson
Hi Christian, On 12 May 2014 at 11:01:36, christian.kitzmuel...@gmail.com (christian.kitzmuel...@gmail.com) wrote: Hi, I think I stumbled over a potential pitfall when using a Processor with a FSM - in case I have a RecoveryFailure the FSM will handle the message via default handling. If I

Re: [akka-user] mixing FSM and akka-persistence

2014-05-08 Thread Akka Team
Hi Nicola, thanks for providing the sample project, I tried it out and the problem is that the FSM never processes a single message when instantiated in a TestFSMRef. It works fine if you change it to system.actorOf(Props(new ...)) and then rely on SubscribeTransitionCallBack to monitor the

Re: [akka-user] mixing FSM and akka-persistence

2014-05-08 Thread Nicola Piccinini
thanks Roland for taking care of it. What about the second part of my email concerning the problem I have recovering the PersistentFSM: -- There are also three objects that you can run FiniteStateMachineSpes - Main AlmostPersistentFSMSpec

Re: [akka-user] mixing FSM and akka-persistence

2014-05-08 Thread Akka Team
On Thu, May 8, 2014 at 3:26 PM, Nicola Piccinini piccin...@gmail.comwrote: thanks Roland for taking care of it. What about the second part of my email concerning the problem I have recovering the PersistentFSM: I think it might well be coupled with the other issue, it seems that the

Re: [akka-user] mixing FSM and akka-persistence

2014-05-08 Thread Nicola Piccinini
What about the second part of my email concerning the problem I have recovering the PersistentFSM: I think it might well be coupled with the other issue, it seems that the TestFSMRef somehow mixes up the Processor internals. but that should not be related in any way with the tests. I am

Re: [akka-user] mixing FSM and akka-persistence

2014-05-06 Thread Nicola Piccinini
hi, I am Nicola (not Christian), I created a github repo for you: https://github.com/pic/akkaTheHutt you have three classes: FiniteStateMachine ( no persistence, extends Actor ) AlmostPersistentFSM ( extends Processor but no use of Persistent ) PersistentFSM ( persistence ) The only

Re: [akka-user] mixing FSM and akka-persistence

2014-05-05 Thread Akka Team
Hi Christian, Do you have a small reproducible test case that exposes the problem? If you do, please share so we can look into the possible issue. -Endre On Sun, May 4, 2014 at 2:07 PM, Nicola Piccinini piccin...@gmail.comwrote: Yes, http://doc.akka.io/docs/akka/snapshot/scala/persistence.

Re: [akka-user] mixing FSM and akka-persistence

2014-05-04 Thread christian . kitzmueller
Hi, I can also confirm that this is working - we are using persistence for recovery of our fsm's (storing initialization messages and do snapshots when stopping/hibernating them) Cheers, Christian Am Samstag, 3. Mai 2014 17:20:46 UTC+2 schrieb Konrad Malawski: Is it possible to use

Re: [akka-user] mixing FSM and akka-persistence

2014-05-04 Thread Nicola Piccinini
Yes, http://doc.akka.io/docs/akka/snapshot/scala/persistence.html#state-machines thank you for the pointer. The problem was that I had overwritten preStart, with something like: super.preStart() self ! Message and that did not play well with Processor. Since it is probably not a good

[akka-user] mixing FSM and akka-persistence

2014-05-03 Thread Nicola Piccinini
hi all, I am trying to do something like: class MyFSM extends Processor with FSM and at first it seems that it does not work properly. Is it possible to use Processor and FSM together? Thanks, Nicola -- Read the docs: http://akka.io/docs/ Check the FAQ:

Re: [akka-user] mixing FSM and akka-persistence

2014-05-03 Thread Konrad Malawski
Is it possible to use Processor and FSM together? Yes, http://doc.akka.io/docs/akka/snapshot/scala/persistence.html#state-machines What problems are you seeing? -- Cheers, Konrad 'ktoso' Malawski hAkker - Typesafe, Inc http://www.scaladays.org/ -- Read the docs: http://akka.io/docs/