Related to JBAS-8517
In OSGi a set of bundles is (hot-) deployed in two phases.
#1 Bundles are installed into the Framework
#2 Bundes are started
After #1 a bundle is in state INSTALLED, the Framework is free to transition the bundle to state RESOLVED at any time. This can explicitly be triggered via PackageAdmin or implicitly by a class loading operation on Bundle.loadClass(String). Bundle.start() transitions the bundle from INSTALLED to RESOLVED to ACTIVE.
Given a set of bundles, it is important that all of them are INSTALLED (without getting started). The expected hot-deploy semantics is however that after the set of bundles got installed an attempt is made to start them.
In AS6 I worked arround that by wrapping the AS Deployers (see JBDEPLOY-214)
In AS7 I would need a notion of post deployment processing hook, that allows me to query the set of successful deployments (i.e. DeploymentServices) so that I can do processing step #2
Currently I work around that by collecting the deployments in a ThreadLocal