public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
        final DeploymentUnit unit = phaseContext.getDeploymentUnit();
        final List<KernelDeploymentXmlDescriptor> kdXmlDescriptors = unit.getAttachment(KernelDeploymentXmlDescriptor.ATTACHMENT_KEY);
        if (kdXmlDescriptors == null || kdXmlDescriptors.isEmpty())
            return;

        final Module module = unit.getAttachment(Attachments.MODULE);
        if (module == null)
            throw PojoLogger.ROOT_LOGGER.noModuleFound(unit);

        final ServiceTarget serviceTarget = phaseContext.getServiceTarget();
        final DeploymentReflectionIndex index = unit.getAttachment(Attachments.REFLECTION_INDEX);
        if (index == null)
            throw PojoLogger.ROOT_LOGGER.missingReflectionIndex(unit);

        for (KernelDeploymentXmlDescriptor kdXmlDescriptor : kdXmlDescriptors) {
            final List<BeanMetaDataConfig> beanConfigs = kdXmlDescriptor.getBeans();
            for (final BeanMetaDataConfig beanConfig : beanConfigs) {
                describeBean(module, serviceTarget, index, beanConfig);
            }
            // TODO -- KD::classloader, KD::aliases
        }
    }
public void deploy ( DeploymentPhaseContext phaseContext ) throws DeploymentUnitProcessingException { final DeploymentUnit unit = phaseContext . getDeploymentUnit ( ) ; final List < KernelDeploymentXmlDescriptor > kdXmlDescriptors = unit . getAttachment ( KernelDeploymentXmlDescriptor . ATTACHMENT_KEY ) ; if ( kdXmlDescriptors == null || kdXmlDescriptors . isEmpty ( ) ) return ; final Module module = unit . getAttachment ( Attachments . MODULE ) ; if ( module == null ) throw PojoLogger . ROOT_LOGGER . noModuleFound ( unit ) ; final ServiceTarget serviceTarget = phaseContext . getServiceTarget ( ) ; final DeploymentReflectionIndex index = unit . getAttachment ( Attachments . REFLECTION_INDEX ) ; if ( index == null ) throw PojoLogger . ROOT_LOGGER . missingReflectionIndex ( unit ) ; for ( KernelDeploymentXmlDescriptor kdXmlDescriptor : kdXmlDescriptors ) { final List < BeanMetaDataConfig > beanConfigs = kdXmlDescriptor . getBeans ( ) ; for ( final BeanMetaDataConfig beanConfig : beanConfigs ) { describeBean ( module , serviceTarget , index , beanConfig ) ; } } }
Process a deployment for KernelDeployment configuration.
Will install a {@code POJO} for each configured bean.

@param phaseContext the deployment unit context
@throws DeploymentUnitProcessingException