Re: update/405 question

"Justin R. Miller" <[email protected]>
Newsgroups gmane.comp.web.sitecopy
Message-ID <[email protected]>
On Feb 19, 2005, at 4:46 AM, Joe Orton wrote:

>> Occasionally, my users will go to perform a backup, which is really
>> just a 'sitecopy -uo <site>' after a previous run was cancelled or
>> otherwise aborted.  Their local sitecopy status cache will be out of
>> sync with the remote version, and when the collection update is
>> attempted, the subdirectories on the server will have already been
>> created so sitecopy fails with a bunch of 405 Method Not Allowed HTTP
>> errors.
>
> The previous run was aborted with Ctrl-C etc locally?  sitecopy's
> handling of that is not very graceful; the ideal fix would be to make 
> it
> more robust.

Basically -- I have a forked processes that can get terminated, or 
times out if the network goes away (I'm working with a lot of mobile 
laptops here).  The quitting is fine, it's just that stuff is 
unpredictable on subsequent runs.

>> Then, sitecopy will exit with errors and throw my app out of whack
>> because, well, it exited with errors.  However, if only sitecopy would
>> try to do the update without the failed mkdir things would be fine.
>>
>> My questions is this:
>>
>> I see in the past (via the archives) that the 405 was changed from a
>> 409 and that is according to spec.  However, is there a less fatal way
>> to handle this situation that could be implemented in sitecopy?  Can't
>> sitecopy just see the directories as already existing and then start
>> uploading the content?
>
> No, because it is as an error as far as sitecopy is concerned.  You can
> use "sitecopy --keep-going --update" and it should carry on past the
> errors; then you could use --catchup to tell sitecopy that the state 
> was
> in synch.

Isn't it risky to use --catchup when the content wasn't actually 
updated?  If part of a directory exists on the server, sitecopy will 
bail with a 405.  Then, I don't have a full backup of the directory on 
the server.

I'm probably not fully understanding what's possible according to the 
WebDAV spec.  I realize you have no control over a 405 by the server, 
but can't you then check to see if it's because the file or directory 
already exists, and if so, upload its content?

-- 
Justin R. Miller
[email protected]

_______________________________________________
sitecopy maillist  -  [email protected]
http://dav.lyra.org/mailman/listinfo/sitecopy
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.