I'm working with the developer of PF4J(Plugin Framework for Java) to provide better plugin functionality for Wicket. There is already a pf4j-spring and a pf4j-wicket project to provide some basic integration. In order to allow the @SpringBean or @Inject annotations to have access to plugin beans in a child context we need to be able to lookup the ApplicationContext associated with a specific class.
So for example, say I have a MyService bean in a child(plugin) ApplicationContext and that plugin also provides a panel that needs that via a @SpringBean annotation. Spring doesn't allow the parent ApplicationContext to see beans in a child context and for good reason. So we would get an exception saying that bean could not be found since @SpringBean only looks up beans in the parent context. We have code that we have developed that look up the child context like so: SpringPlugin plugin = (SpringPlugin)PluginManager.whichPlugin(MyService.class); ApplicationContext pluginContext = plugin.getApplicationContext(); How could I modify or provide this functionality in a custom version of SpringComponentInjector? It uses a ISpringContextLocator but that context locator does not specify the class for which it needs the ApplicationContext. Any ideas on how this could be achieved? Thanks for your help! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/SpringBean-support-for-bean-in-child-ApplicationContext-tp4673719.html Sent from the Users forum mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org