I think I'm going to be disagreeable ...
On 2005.6.3, at 05:23 AM, Jay Savage wrote:
On 6/2/05, Bill Stephenson <[EMAIL PROTECTED]> wrote:
On Jun 1, 2005, at 4:40 PM, Jay Savage wrote:
Bill,
Just upload the file to something like "my_script.cgi.new". It can
take as long as it needs to transfer. Once it's transferred, rename
it.
HTH,
-- jay
--------------------
daggerquill [at] gmail [dot] com
http://www.engatiki.org
Thanks for the reply Jay,
I've done that too, but it's a rather laborious solution to what must
be a rather common task and I'm thinking there could be a more
automated way to deal with it. Since both BBEdit and Interarchy are
already built to work together I was hoping that someone more familiar
with their guts may have worked on it already.
So I guess what I'm asking is if there a way to get either of these
apps to upload a file with a new name and rename it after the upload
is
complete with one click. Obviously, this doesn't entirely solve the
problem, but it does reduce the potential.
Kindest Regards,
The answer is probably no. At least not out of the box. It's not
really all that common, at least not any more: most "mission critical"
apps are maintained on reasonably high speed connections.
Race conditions don't go away just because you have high speed
connections.
In most
cases if you're working on an application where a customer just
absolutely can't get a 505 error, ever. The comapany pays for a cable
or T1--or at least DSL--connection. And usually, if it's that
important, especially if you're using renaming to aviod connection
problems, you don't want the process to be automated. You want to do
it by hand to make sure it works, and you want to verify the checksums
on both the download and the upload, just to be sure you've got
everything. So no, this probably isn't as common as it seems,
although it was certainly more common 5 years ago.
That said, interarchy is extremely AppleScriptable.
Bingo.
In fact, I'll bet you can get into Interarchy through perl, but then
you can also go direct to ftp or ssh through perl, as well. Set up an
entire separate directory hierarchy, shut down the sessions more or
less gracefully, and mv the root of the new one over the top of the old
one before bringing the server back up.
And the really big sites actually load the new site on a separate (set
of) server(s) and switch the IP addresses all at once.
You should be
able to whip up something fairly quickly. If you poke around the
Interarchy users group (it's linked from the website) there may even
be something out there already.
Anothe option would be to set up a cron job on the server to
periodically rename files with a certain extension.
HTH,
-- jay
--------------------
daggerquill [at] gmail [dot] com
http://www.engatiki.org