1 Reply Latest reply on Feb 10, 2008 12:57 AM by Ales Justin

    Question on Capabilities definition (ClassLoaderMetaData)

    Gilles Compienne Newbie


      Looking at the JBoss MC source code I can see that a "describe" deployer can add capabilities information before the classloader gets created("ClassLoaderMetaData.setCapabilities()"), thus allowing dependency resolution for a unit being deployed.

      Now, I wonder about the deployer themselves: How could a deployer (that is being deployed) inform MC of its own capabilities?

      Is there a mechanism to do that? The only option I can see, so far, is to create another deployer (in a different deployment unit) that would declare the capabilities my deployer. But I can't shake the feeling that I am probably trying to kill a fly with a hammer... ;-)

      Thanks for your help.


        • 1. Re: Question on Capabilities definition (ClassLoaderMetaData
          Ales Justin Master

          I don't understand what you mean by deployer having capabilities.

          It's the module that has capabilities.
          And there is a module per deployment unit.

          Module also has requirements.
          It is mean that those requirements are usually resolved by some other module's capabilities.

          Think of this as OSGi imports (requirements) and exports (capabilities).
          And there are also bundle dependencies - module requirement / capability.

          You would normally have this information constructed in a single deployer - e.g. OSGiManifestParser.

          But deployer is nothing more than a POJO inside MC.
          So it can have all the normal IoC/DI stuff as other MC beans.