monster
unread,May 20, 2013, 5:44:11 AM5/20/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to agilewiki...@googlegroups.com
Well, idk how this configuration, or whatever you had in mind, should work.
But personally, I think the ideal configuration would work like dependency-injection. You have your actor, and it has "fields" containing what it needs to do it's job. That could be simple value properties, or singleton, or whatever. And you have your "configurator" (like a Guice module), that connects to whatever source of configuration information you want to use (local property file, LDAP directory, SQL DB, ... whatever) and somehow tracks changes. When changes happen, it pushes them to the "configured actors" using requests, which probably requires the actors to implement specific interfaces. So the actors do not need to know where the vales come from, and when they change. All they need to know, is that they don't change while they are processing a message/response. I think this is like a generalisation of what you do with the service tracker, right? So one issue is the "initialization", as the actor can probably not process any messages until it was fully configured once.
An alternative to creating specific configurators would be to have configuration listener interfaces, and automatically register actors that implement them as configurable actors.
What does that sound like?