<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<tt>Stuart says<br>
</tt>
<blockquote><i><tt>In that case we will need two manifest attachment
processors, as we also need to pick up the manifests of
resource roots that are added by other processors, (e.g.
WEB-INF/ lib jars)</tt><br>
</i></blockquote>
<tt>Currently, there is at most one Manifest attachment to the
DeploymentContext. The OSGi Manifest Processor checks if that
Manifest exists and contains valid OSGi metadata. This qualifies a
deployment as OSGi bundle.<br>
<br>
Manifests that come from nested artefacts, could perhaps be added
under a different key (i.e. not the Manifest for the deployment
root). DUPs should either be able to process OSGi bundle
deployments or alternatively ignore them if they cannot do that
(just yet).<br>
<br>
Perhaps a processor order like this would work<br>
<br>
public static final int STRUCTURE_MANIFEST = 0x0100;<br>
</tt><tt> public static final int STRUCTURE_OSGI_MANIFEST =
0x0200;<br>
</tt><tt> public static final int STRUCTURE_NESTED_MANIFEST =
0x0300;<br>
</tt><tt> public static final int STRUCTURE_RAR = 0x0400;<br>
public static final int STRUCTURE_WAR_DEPLOYMENT_INIT =
0x0500;<br>
...<br>
<br>
cheers<br>
-thomas<br>
<br>
</tt><br>
On 03/16/2011 10:11 AM, Thomas Diesler wrote:
<blockquote cite="mid:4D807EB6.2050703@jboss.com" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<div class="moz-text-flowed" style="font-family: -moz-fixed;
font-size: 12px;" lang="x-western">Folks, <br>
<br>
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 <br>
<br>
DeploymentUnit deploymentUnit =
phaseContext.getDeploymentUnit(); <br>
if(deploymentUnit.hasAttachment(Attachments.OSGI_MANIFEST)) { <br>
return; <br>
} <br>
<br>
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 <br>
<br>
// STRUCTURE <br>
public static final int
STRUCTURE_MOUNT = 0x0000; <br>
public static final int
STRUCTURE_MANIFEST = 0x0100; <br>
public static final int
STRUCTURE_OSGI_MANIFEST = 0x0200; <br>
public static final int
STRUCTURE_RAR = 0x0300; <br>
... <br>
<br>
This relates to a bug related to WAB (Webapp Bundle) deployments
<br>
<a moz-do-not-send="true" class="moz-txt-link-freetext"
href="https://issues.jboss.org/browse/JBAS-8940">https://issues.jboss.org/browse/JBAS-8940</a>
<br>
<br>
cheers <br>
-thomas <br>
<br>
<br>
<div class="moz-txt-sig"><span class="moz-txt-tag">-- <br>
</span>xxxxxxxxxxxxxxxxxxxxxxxxxxxx <br>
Thomas Diesler <br>
JBoss OSGi Lead <br>
JBoss, a division of Red Hat <br>
xxxxxxxxxxxxxxxxxxxxxxxxxxxx </div>
</div>
<br>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
jboss-as7-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:jboss-as7-dev@lists.jboss.org">jboss-as7-dev@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/jboss-as7-dev">https://lists.jboss.org/mailman/listinfo/jboss-as7-dev</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Thomas Diesler
JBoss OSGi Lead
JBoss, a division of Red Hat
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
</pre>
</body>
</html>