<!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">JBoss 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;">
    Re: Thoughts on filesystem action driven hot deployment
</h3>
<span style="margin-bottom: 10px;">
    created by <a href="http://community.jboss.org/people/bstansberry%40jboss.com">Brian Stansberry</a> in <i>JBoss AS7 Development</i> - <a href="http://community.jboss.org/message/570597#570597">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>This forum interface drives me nuts. As I write this I'm chatting about what public mailing list we should use for AS 7 dev discussions.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Re: the remotable API to upload individual files w/in a deployment, let's discuss next week and then I'll open a JIRA.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Re: Windows jar locking with exploded deployments -- from various discussions I have a vague feeling it may be possible to avoid that without copying.&#160; I'm doubtful. Bottom line is if when this is implemented we have to copy to avoid file locking problems, we'll copy.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><blockquote class="jive-quote"><p>Max Andersen wrote:</p><blockquote class="jive-quote"><blockquote class="jive-quote"><p> If we're going to leave the original file around, for zipped files IMO we should do away with the marker files, and use them solely for exploded deployments, where they have a clear purpose. If the zipped files are left around, the only thing the marker files provide is an indication that the content&#160; was actually deployed. There are other ways to see that; and by itself that's not justification for the confusion of having two files around.</p></blockquote>
<p>I agree - if the file stays around the marker file has no real importance.</p>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>Well, maybe for consistency and actually knowing the file got deployed without having to scan logs ?</p>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>Or is there other/better ways to get this info now ?</p></blockquote></blockquote><p>When anything is deployed, an entry for it is written in the standalone/configuration/standalone.xml file.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><blockquote class="jive-quote">How are users to know where the actual deployment is happening from ? Suggestion: put a deploy.location=/var/tmp/blahbla/foo.war into the marker file - simply for ease of debugging/transparency.<blockquote class="jive-quote"><blockquote class="jive-quote"><p>I've been tempted to do that. Haven't because 1) it forms a semi-contract that I'm not sure we should commit ourselves to. 2) It also encourages poking around in places users aren't meant to go poking. 3)&#160; It also forces the deployment content repository to expose internal implementation details to the deployment scanner service, which isn't the end of the world but isn't nice either.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>There is INFO level logging of where the deployment content is stored (which shoots my #2 above). :-)</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p></blockquote>
<p>I keep hearing this "by exposing the actual deployment location there is a semi-contract"-excuse and I just don't buy it.</p>
<p>The deployment is going to be *somewhere* wether that is on the filesystem or in-memory then telling the user where it is being 'read' from is never a bad information to have.</p>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>And as you said - it gets logged anyway (for a reason I assume ? <span> :) </span></p>
</blockquote></blockquote><p>I have no serious objection to telling people where deployments are stored. This is OSS after all. As we go along there should be a wiki page describing exactly how this works for a given release. I'm just doubtful about persisting it in this file. People come to count on reading the file and you can't lightly stop writing it even if it becomes a problem.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><blockquote class="jive-quote">Why have markers both at toplevel /foo.war.deployed and foo.war/META-INF/jboss-deploy - why not just have them as foo.war.deploy (request deployment of foo.war) and foo.war.deployed (marker for foo.war have been deployed) ? More consistent IMO. <blockquote class="jive-quote"><blockquote class="jive-quote"><p>Fine with me.</p></blockquote>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>At submodule deployments it might make sense to have other markers at a different "Depth" but when its the "same" thing you trigger a redeploy of the marker should be the same.</p></blockquote></blockquote><p>There's no plan to support independent redeployment of submodules.</p><blockquote class="jive-quote">The downside to that is multiple changes can't be made as an atomic unit, with no requests seeing only some of the changes. But&#160; I don't think that's a critical use case. Devs doing testing will deploy content, make some requests, update some files in the deployment, make some requests, etc. They're not making requests in the middle of copying in changed files.<blockquote class="jive-quote">
<p>This is actually a critical use case. Today we use jmx calls to tell AS to *not* scan folders while we are copying files over and then continue when we are done. If we didn't do that you would see *alot* more failure deployments.</p>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>i.e. users updating a jar or set of jars - that copy operation will actually take some ms's or even seconds for large jars and without disabling the scanner we see alot more partial deployments.</p>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>This can happen both on the initial creation of the foo.war or during editing/changes.</p>
<p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p>
<p>I think it would be great have a marker file to prevent deployment - i.e. foo.war.nodeploy would make the scanner skip checking foo.war. Then the tool or user can remove it when he wants it in play again.</p>
</blockquote></blockquote><p>Doesn't the .deploy file mechanism deal with this? With an exploded deployment, the user has to add that file to trigger redeploy. Once the thing is deployed, changing the contents changes what's visible as a resource to the deployment's classloader, but the scanner doesn't do a full redeploy just because it detects some of the content changed.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>I suspect this is leading into the subject of hot replacement of classes, which sounds like a good topic for over a beer next week.</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/570597#570597">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss AS7 Development at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2225">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>