--
You received this message because you are subscribed to the Google Groups "google-guice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-guice...@googlegroups.com.
To post to this group, send email to google...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/d/optout.
I hate to break it to you, but it increasingly looks like you're making this much harder for yourself, using the framework in a way it's not intended.
For this particular problem (adding things to a shared pool), there's an extension called Multibinder: http://code.google.com/p/google-guice/wiki/Multibindings .
For other issues, you may want to consider asking for specific guidance and help in StackOverflow (or searching for existing questions/answers). I suspect you'll find that things will become a lot simpler.
sam
It does depend on how you're doing your listener pattern, but Guava's EventBus might be a nice alternative, like I explained in an earlier email.
I think Sam was just pointing out that it seems like you're using Guice in an unintended way. Which can decrease the satisfaction of your particular experience.
Which, of course is a shame, because Guice has been an amazing experience for me, and I won't do any project without it.
It should technically be possible to have a two stage dependency injection setup. I've personally toyed with the idea as a way to decouple configuration from the application (before I started using dropwizard I used multiple json files that would auto inject @Named strings). It should work in your case as well if you name your collections and inject them into your modules.
So the idea is that the first injector is created to instantiate all modules, so you would need very few super modules that binds each of your original modules. You will likely want to use multibinder to register each module so that you can pull them directly off of this initial injector to construct the second phase injector.
It should work and may help with the problem you've found yourself in.
If you feel like you can share a handful of module source files with me, out of thread, I'd be happy to see if there are even better and more concrete suggestions I can give you.
Nate
You received this message because you are subscribed to a topic in the Google Groups "google-guice" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-guice/HMj5hmPjmR4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-guice...@googlegroups.com.
To post to this group, send email to google...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "google-guice" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-guice/HMj5hmPjmR4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-guice+unsubscribe@googlegroups.com.
To post to this group, send email to google...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/d/optout.
You bring up a good point... Why does this list exist? It existed prior to the fantastic take off of the stack exchange platform and so we should consider the modern purpose of this list. Thank you for pointing out this mis-match of purposes.
I will start a separate thread to discuss the purpose of this list and ways to better curate its content, ways to steer people to the best resources, and how we can publicize that. This was very useful feedback upon consideration.
You received this message because you are subscribed to the Google Groups "google-guice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-guice...@googlegroups.com.
--
--
You received this message because you are subscribed to a topic in the Google Groups "google-guice" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-guice/HMj5hmPjmR4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-guice...@googlegroups.com.
To post to this group, send email to google...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "google-guice" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-guice/HMj5hmPjmR4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-guice...@googlegroups.com.
To post to this group, send email to google...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/d/optout.
Interesting! Have you found a significant performance overhead? I tend to hide bindings like these in a private module, but I doubt that would make their cost any cheaper. Can you explain what the cons are from this approach? I do things like this all the time now.
Thanks,
Nate
-dirk
--
You received this message because you are subscribed to a topic in the Google Groups "google-guice" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-guice/HMj5hmPjmR4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-guice...@googlegroups.com.
To post to this group, send email to google...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/d/optout.