While discussing how the OSGi service layer works,
we came up with a better way of doing something that is already supported
in the Microcontainer.
An example would be the new deployers configuration
where you "manually" install deployers into the main deployer, e.g.
| <!--
| Security Deployer
| -->
| <deployment xmlns="urn:jboss:bean-deployer:2.0">
| <bean name="SecurityDeployer"
class="org.jboss.deployment.security.SecurityDeployer">
| <install bean="MainDeployer" method="addDeployer">
| <parameter>
| <this/>
| </parameter>
| </install>
| <uninstall bean="MainDeployer"
method="removeDeployer">
| <parameter>
| <this/>
| </parameter>
| </uninstall>
| <property name="type">security</property>
| <property name="ignoreSuffixes">
| <set elementClass="java.lang.String">
| <value>xml</value>
| <value>beans</value>
| <value>deployer</value>
| </set>
| </property>
| </bean>
| </deployment>
|
The idea is to remove the install and uninstall from the individual deployer xmls
and instead configure the MainDeployer to want all implementations
of a specific class, in this case org.jboss.deployers.spi.deployer.Deployer
and have the Microcontainer do the add/remove invocations.
| /**
| * Add a deployer
| *
| * @param deployer the deployer
| */
| @Install
| public synchronized void addDeployer(Deployer deployer) { ... }
|
| /**
| * Remove a deployer
| *
| * @param deployer the deployer
| */
| @Uninstall
| public synchronized void removeDeployer(Deployer deployer) { ... }
|
This feature is being tracked here:
http://jira.jboss.com/jira/browse/JBMICROCONT-165
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4032377#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...