> May I ask what difference it makes how it is implemented? I'm just curious? Does akka use 'synchronized' internally?
> As long s those mutable things are not modified outside of the actor you're just fine. Thanks for confirming this! - Andrey 17 януари 2014, петък, 15:21:46 UTC+2, √ написа: > > Hi Andrey, > > > On Fri, Jan 17, 2014 at 1:20 PM, Andrey Petrov <[email protected]<javascript:> > > wrote: > >> > In layman's terms this means that changes to internal fields of the >> actor are visible when the next message is processed by that actor. >> > So fields in your actor need not be volatile or equivalent. >> I apologize if this has been asked before, but how does akka guarantee >> that when the actor is scheduled back and forth between threads, each >> thread will see the correct (latest) version of the actor state? I guess my >> question is how is this implemented internally in akka? >> > > May I ask what difference it makes how it is implemented? > > >> >> Also, what if my actor state contains references to mutable objects? I >> understand I don't have to worry about the actor fields themselves, but >> what about the mutable objects they refer to? Are those synchronized >> automatically by akka for me as well? And if so, can we make the docs a bit >> more explicit about this? >> > > As long s those mutable things are not modified outside of the actor > you're just fine. > > Cheers, > √ > > -- >> >>>>>>>>>> Read the docs: http://akka.io/docs/ >> >>>>>>>>>> Check the FAQ: http://akka.io/faq/ >> >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user >> --- >> You received this message because you are subscribed to the Google Groups >> "Akka User List" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> To post to this group, send email to [email protected]<javascript:> >> . >> Visit this group at http://groups.google.com/group/akka-user. >> For more options, visit https://groups.google.com/groups/opt_out. >> > > > > -- > Cheers, > √ > > * Viktor Klang* > *Concurrent, Distributed* > > Twitter: @viktorklang > -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: http://akka.io/faq/ >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/groups/opt_out.
