[jboss-as7-dev] Account for OSGi bundles in DeploymentUnitProcessors

Ales Justin ales.justin at gmail.com
Wed Mar 16 05:22:31 EDT 2011


As I already commented on the JIRA issue, this approach just won't fly in the long run.
Imagine every similar sub-system as OSGi that would need to be excluded all over the place.

I'm also not saying this should be done immediately,
but I hope you have a long term vision where this kind of approach won't be needed.
Imo, this is what OSGi EE should be all about, to be able to run side-by-side, properly integrated, not explicitly excluded.

On Mar 16, 2011, at 10:11 AM, Thomas Diesler wrote:

> Folks, 
> 
> an OSGi bundle deployment is fundamentally different from an EE deployment and must be handled by the OSGi subsystem. DUPs that are not targeted for OSGi bundle deployments must ignore these. Currently the recommended approach to ignore an OSGi deployment in a DUP is 
> 
>         DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); 
>         if(deploymentUnit.hasAttachment(Attachments.OSGI_MANIFEST)) { 
>             return; 
>         } 
> 
> If you work on some other type of marker attachment, make sure that this marker is not attached for an OSGi deployment. For the above check to work, the OSGi manifest processor must come early in the chain. I changed the order of structure processors to 
> 
>     // STRUCTURE 
>     public static final int STRUCTURE_MOUNT                             = 0x0000; 
>     public static final int STRUCTURE_MANIFEST                          = 0x0100; 
>     public static final int STRUCTURE_OSGI_MANIFEST                     = 0x0200; 
>     public static final int STRUCTURE_RAR                               = 0x0300; 
>     ... 
> 
> This relates to a bug related to WAB (Webapp Bundle) deployments 
> https://issues.jboss.org/browse/JBAS-8940 
> 
> cheers 
> -thomas 
> 
> 
> -- 
> xxxxxxxxxxxxxxxxxxxxxxxxxxxx 
> Thomas Diesler 
> JBoss OSGi Lead 
> JBoss, a division of Red Hat 
> xxxxxxxxxxxxxxxxxxxxxxxxxxxx
> 
> _______________________________________________
> jboss-as7-dev mailing list
> jboss-as7-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jboss-as7-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-as7-dev/attachments/20110316/5f53cea0/attachment.html 


More information about the jboss-as7-dev mailing list