Subject: webFolders PUT

From: Madan Mohan <[email-masked]>
Date: Mon, 9 Oct 2000 11:29:12 -0700

Hi 

I am writing a Java servlet which listens to WEBDAV reqests and responds to
them. Using web folders as my client. I am able to create and delete
folders. The problem comes when i drag and drop a file from my local disk
into the web folder. My sniffer says that web folders makes a head and put
and head. Now the PUT has content length of 0. HAve i done something wrong
here. So how to I copy the file to the server when web folders does not send
me the file data. What response should i give for this PUT with 0 content
length?

MAdan

---

From: [email-masked] (WJCarpenter)
Date: Mon, 9 Oct 2000 11:49:10 -0700

madan> I am writing a Java servlet which listens to WEBDAV reqests and
madan> responds to them. Using web folders as my client. I am able to
madan> create and delete folders. The problem comes when i drag and
madan> drop a file from my local disk into the web folder. My sniffer
madan> says that web folders makes a head and put and head. Now the
madan> PUT has content length of 0. HAve i done something wrong
madan> here. So how to I copy the file to the server when web folders
madan> does not send me the file data. What response should i give for
madan> this PUT with 0 content length?

My advice is to make a zero-length file and declare success.  After
all, it's completely legal.  Web Folders is trying to make sure it can
create the file before it sends the content.  You didn't say, but
usually the sequence you mentioned is quickly followed by another PUT
with the real content.

Someone locally suggested that Web Folders does it this seemingly zany
way to emulate the way MSWindows implementations deal with local file
systems.  It doesn't cost much with local file systems to do it that
way.
-- 
[email-masked] (WJCarpenter)    PGP 0x91865119
38 95 1B 69 C9 C6 3D 25    73 46 32 04 69 D6 ED F3