DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=37897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=37897





------- Additional Comments From [EMAIL PROTECTED]  2006-01-15 03:17 -------
After researching this problem, I found a workaround that reduces the problem,
although the behavior is different, and might not work for some use cases.

If you use the <modified> selector on the fileset, then ant will
keep track of changes made to the local copies of the files, and only
the modified files will be selected for the ftp transfer.

For my case, this works just the same as the "depends=true" option
for the <ftp> task, but the behavior is slightly different.  "depends"
option forces a comparison of the timestamps of the files on the server
and the files on the local filest, whereas <modified> works only with
the local files. There is a potential for a disconnect if the files on
the server are reverted to an older version; For example, I am doing
software development on enterprise web applications. If I reinstall my
server with a different version of the software after I have already invoked
the <ftp> tasks on my machine; Then the server will not have the updated
jsp, etc. files I am actively working on, and when I run the <ftp> task again,
the newer versions will not be transfered because I haven't changed them
locally since the server software was reinstalled. 

Since I have full control of the server I am ftping the files to, if the above
situation happpens, I can just remove the cache.properties file that the
<modified> selector uses, and then the <ftp> will transfer all files the next
time invoked.

<ftp server="${SERVER_NAME}"
     userid="${SERVER_USER}" password="${SERVER_PASSWORD}"
     remotedir="/usr/pronto/web/html/jsp"
     verbose="yes">
     <fileset dir="${TOP}/web/html/jsp">
        <include name="*.jsp"/>
        <include name="*.jspf"/>
        <modified>
          <param name="cache.cachefile"
value="${TMP_DIR}/ftp-jsp-cache.properties"/>
        </modified>
     </fileset>
</ftp>

I recommend that the ftp task should include a reference to
the <modified> selector. Because I didn't even think to use
that until I found a reference to it on the web.

http://ant.apache.org/manual/CoreTypes/selectors.html#modified

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to