Hi Michael, Martynas,

Thanks for all the feedback. I added a second example and will add a third 
soon.

Of course you can design the methods in  the trait as you like. Sometimes 
you may want
to hide the message, sometimes not. I think this depends on the use case. 

And yes, you are absolutely right regarding typesafety on the 
implementation side.
On the consumerside you have typed methods, which makes it easier. However 
you
have to provide the correct actorRef, which is a problem this pattern 
doesn't try to solve.

My biggest fear is, that using this pattern will escalate in 
overengineering stuff you actually
can solve a lot easier. Maybe it's a nice starter for beginners as you 
mentioned.

thanks again,
Muki

PS: Yeah, I'll try to pull an activator out of this

Am Donnerstag, 31. Juli 2014 09:52:34 UTC+2 schrieb Michael Pisula:
>
> Hi Muki,
>
> I like the pattern. In details I would use it a bit different though. I do 
> not like that some of the logic is hidden in the trait, I would prefer only 
> to pass the messages to typed receive methods in greetingReceive. 
>
> It does not add any real typesafety though, as there is no way to ensure 
> that the actor passed into your consumer actually meets the contract, 
> therefore I would not really see it as an alternative to typed actors, but 
> as a way to document and enforce the contracts between two actors. The 
> wiring of the actors still can go wrong and is not enforced in any way. 
> Still, I think this is a worthwhile pattern especially when facing 
> developers new to Akka or very complex actor wiring.
>
> I would love to see an Activator Template with a more complex example 
> using this pattern.
>
> Cheers,
> Michael
>
> Am Donnerstag, 31. Juli 2014 00:06:02 UTC+2 schrieb Muki:
>>
>> Hi,
>>
>> I created a small sample app for a little architecture pattern for akka 
>> applications.
>> The idea can be terribly wrong, but I wanted to get some feedback on it:
>>
>>    https://github.com/muuki88/akka-architecture
>>
>>
>> The  README explains the pattern and how to apply it. It's more or less a 
>> way
>> around typed actors. 
>>
>> cheers,
>> Muki
>>
>>

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      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 akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to