java - Spring dependency injection from webapp to external jars -


i integrating java plugin framework within spring based web application (xml-free).

everything fine, except dependency injection in plugin context

for instance have data source use in plugin without having go property files using @autowired rest of application

i cannot find way except using getbean, read not best practise on subject.

i had @ logicaldoc project resorts properties reloading not correct solution me want beans attributes modifications available without further glue.

does know of existing open source project both these environment used ?

not being able inject dependencies in plugins, added following methods mother class of plugins

   public void setcontext(applicationcontextprovider a_ctx) {         m_thecontext = a_ctx;    }    public applicationcontext getapplicationcontext() {         return m_thecontext.getapplicationcontext();    } 

and retreive beans within plugin

getapplicationcontext().getbean(*classtype*) 

Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -