<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">
<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>
                                <td>
                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">Community</a></h1>
                                                                </td>
                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px; -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
ShrinkWrapDeployer
</h3>
<span style="margin-bottom: 10px;">
reply from <a href="http://community.jboss.org/people/ALRubinger">Andrew Rubinger</a> in <i>JBoss Microcontainer Development</i> - <a href="http://community.jboss.org/message/540878#540878">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">
<div class="jive-rendered-content"><p>Realtime discussion:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p><span style="color: #204a87; font-size: 10pt; ">(04:10:23 PM) </span>ALR@MSN: About ShrinkWrapDeployer: let me ask you:<br/><span style="color: #cc0000; font-size: 10pt; ">(04:10:30 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">shoot</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:10:35 PM) </span>ALR@MSN: Where's the component that bridges VFS inputs to the Deployers ?<br/><span style="color: #cc0000; font-size: 10pt; ">(04:10:47 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">vfs inputs?</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:10:51 PM) </span>ALR@MSN: VirtualFile.<br/><span style="color: #204a87; font-size: 10pt; ">(04:10:55 PM) </span>ALR@MSN: How do you deploy one?<br/><span style="color: #cc0000; font-size: 10pt; ">(04:11:07 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">VFSDeployment extends Deployment</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:11:17 PM) </span>ALR@MSN: Right.  Where does VFSDeployment live?<br/><span style="color: #cc0000; font-size: 10pt; ">(04:11:27 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">jboss-deployers-vfs-spi</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:11:42 PM) </span>ALR@MSN: Where should the component that bridges SW Archive inputs to Deployers be?<br/><span style="color: #cc0000; font-size: 10pt; ">(04:12:02 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">hmmm ...</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:12:13 PM) </span>ALR@MSN: Say it.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:12:16 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">hehe</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:12:16 PM) </span>ALR@MSN: jboss-deployers-shrinkwrap. ;D<br/><span style="color: #cc0000; font-size: 10pt; ">(04:12:19 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">hmmmm ...</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:12:21 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">nope</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:12:24 PM) </span>ALR@MSN: Hahahahaha!<br/><span style="color: #cc0000; font-size: 10pt; ">(04:12:33 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">vfs spi is really a spi ... and it has actual impl</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:12:45 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">whereas your sw stuff is wrapper/facade</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:12:50 PM) </span>ALR@MSN: ShrinkWrapDeployers is just an impl.<br/><span style="color: #204a87; font-size: 10pt; ">(04:12:56 PM) </span>ALR@MSN: The SPI part is yes, a wrapper.<br/><span style="color: #204a87; font-size: 10pt; ">(04:13:03 PM) </span>ALR@MSN: But there's only one reason why:<br/><span style="color: #204a87; font-size: 10pt; ">(04:13:21 PM) </span>ALR@MSN: I need to mount and unmount archives as VFS alongside the deployment/undeployment process<br/><span style="color: #204a87; font-size: 10pt; ">(04:13:36 PM) </span>ALR@MSN: So I can't make the equivalent of VFSDeploymentFactory and call it a day.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:13:45 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">true</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:13:48 PM) </span>ALR@MSN: On undeploy we need to unmount.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:14:18 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">your SW is just another api for VFS</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:14:27 PM) </span>ALR@MSN: Correct.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:14:32 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">hence it's a wrapper/facade</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:14:39 PM) </span>ALR@MSN: Well, no.<br/><span style="color: #204a87; font-size: 10pt; ">(04:14:45 PM) </span>ALR@MSN: SW doesn't wrap VFS.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:14:47 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">if we didn't have vfs, then I would say yes, put it into deployers</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:14:51 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">but we a;ready have vfs</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:14:53 PM) </span>ALR@MSN: We have, however, a VFS adaptor<br/><span style="color: #cc0000; font-size: 10pt; ">(04:15:17 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">yeah, you need to adapt Archive to VFSDeployment</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:15:27 PM) </span>ALR@MSN: Right.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:15:34 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">== facade</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:15:44 PM) </span>ALR@MSN: And if not for the unmounting, I could do it the same way as in VFSDeploymentFactory<br/><span style="color: #204a87; font-size: 10pt; ">(04:15:58 PM) </span>ALR@MSN: With no new deploy/undeploy APIs.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:16:18 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">why's that?</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:16:33 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">why is mounting/unmoounting an issue?</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:16:37 PM) </span>ALR@MSN: VFSDeployment deployment = ShrinkWrapDeploymentFactory.createDeployment(archive); // Easy<br/><span style="color: #204a87; font-size: 10pt; ">(04:16:49 PM) </span>ALR@MSN: Because I need to mount it using a ShrinkWrap extension.<br/><span style="color: #204a87; font-size: 10pt; ">(04:16:58 PM) </span>ALR@MSN: ArchiveFileSystem.<br/><span style="color: #204a87; font-size: 10pt; ">(04:17:10 PM) </span>ALR@MSN: Which is what enables VFS to read SW<br/><span style="color: #204a87; font-size: 10pt; ">(04:17:41 PM) </span>ALR@MSN: You guys do inspection to mountReal or mountJar or something.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:17:47 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">aha, so when asked if it's already mounted, it says true</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:17:54 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">hence it doesn't do mounting</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:18:01 PM) </span>ALR@MSN: "it"?<br/><span style="color: #cc0000; font-size: 10pt; ">(04:18:17 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">mounting mechanism inside deployers</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:18:21 PM) </span>ALR@MSN: After it comes into MainDeployer, nothing will mount it, yes.<br/><span style="color: #204a87; font-size: 10pt; ">(04:18:32 PM) </span>ALR@MSN: We mount.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:18:56 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">if you didn't?</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:19:06 PM) </span>ALR@MSN: Then something in deployers would need to.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:19:10 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">i guess structiure deployers would try and fail?</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:19:14 PM) </span>ALR@MSN: And unmount it when undeployed.<br/><span style="color: #204a87; font-size: 10pt; ">(04:19:26 PM) </span>ALR@MSN: Right.  getChildren would return nothing.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:19:31 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">no</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:19:53 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">see AbstractVFSArchiveStructureDeployer</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:20:57 PM) </span>ALR@MSN: <a class="jive-link-external-small" href="http://fisheye.jboss.org/browse/JBossAS/projects/jboss-deployers/trunk/deployers-vfs/src/main/java/org/jboss/deployers/vfs/plugins/structure/AbstractVFSArchiveStructureDeployer.java?r=101137">http://fisheye.jboss.org/browse/JBossAS/projects/jboss-deployers/trunk/deployers-vfs/src/main/java/org/jboss/deployers/vfs/plugins/structure/AbstractVFSArchiveStructureDeployer.java?r=101137</a><br/><span style="color: #204a87; font-size: 10pt; ">(04:21:01 PM) </span>ALR@MSN: So why "no"?<br/><span style="color: #cc0000; font-size: 10pt; ">(04:21:50 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">it would try to mount</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:21:53 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">and probably fail</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:21:55 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">or not?</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:21:58 PM) </span>ALR@MSN: Oh, right<br/><span style="color: #204a87; font-size: 10pt; ">(04:22:05 PM) </span>ALR@MSN: Because it'd be using the wrong FileSystem.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:22:09 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">yes</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:22:47 PM) </span>ALR@MSN: I have no qualms with removing the wrapper API<br/><span style="color: #204a87; font-size: 10pt; ">(04:22:59 PM) </span>ALR@MSN: If you wanna make structure deployers figure out how to mount it properly<br/><span style="color: #cc0000; font-size: 10pt; ">(04:22:59 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">perhaps this should made possible</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:23:04 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">yes</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:23:05 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">exactly</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:23:10 PM) </span>ALR@MSN: But I assumed you didn't wanna back that logic in.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:23:21 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">didn't think of that</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:23:41 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">how would we recognize which FS we need to mount?</span><br/><span style="color: #cc0000; font-size: 10pt; ">(04:23:43 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">hmmm ...</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:23:45 PM) </span>ALR@MSN: No idea.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:23:48 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">:-)</span><br/><span style="color: #204a87; font-size: 10pt; ">(04:24:07 PM) </span>ALR@MSN: VirtualFile is just a pointer.<br/><span style="color: #204a87; font-size: 10pt; ">(04:24:15 PM) </span>ALR@MSN: You'd have to rely on exceptions for flow control.<br/><span style="color: #204a87; font-size: 10pt; ">(04:24:25 PM) </span>ALR@MSN: ie. try and catch the exception if it's not a SW archive.<br/><span style="color: #204a87; font-size: 10pt; ">(04:24:33 PM) </span>ALR@MSN: Which is no good solution.<br/><span style="color: #cc0000; font-size: 10pt; ">(04:25:07 PM) </span>Ales: <span style="color: #000000; font-size: 12pt; font-family: Helvetica; ">i'll think about it a bit</span></p></div>
<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
<p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/540878#540878">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss Microcontainer Development at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2115">Community</a></p>
</div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>