Hi all,

to avoid concurrent modification problems, I'm trying to use an
exclusive lock on a directory in the WebDAV repository. I can lock and
unlock the directory with no problems, but as soon as I try to PUT a
file in the locked directory, I get a 423 Locked response.

Here's the header from the Lock Method:

LOCK /jcr-webdav/repository/default/audit/staging/files HTTP/1.1
Content-Type: text/xml; charset=utf-8
User-Agent: Jakarta Commons-HttpClient/2.0final
Host: loire:8080
Content-Length: 238
Authorization: Basic FKOtaEWDFWEFRtaW4=
Depth: infinity
Timeout: Infinite, Second-2147483647

Response: HTTP/1.1 200 OK

Here's the PUT header:

PUT /jcr-webdav/repository/default/files/n1201787394075 HTTP/1.1
If: <b257cb01-0a63-4841-abe6-744b95f41ae2-F>
User-Agent: Jakarta Commons-HttpClient/2.0final
Host: loire:8080
Content-Length: 1480
Authorization: Basic FKOtaEWDFWEFRtaW4=

Response: HTTP/1.1 423 Locked

Finally, the header from the Unlock:

UNLOCK /jcr-webdav/repository/default/audit/staging/files HTTP/1.1
User-Agent: Jakarta Commons-HttpClient/2.0final
Host: loire:8080
Authorization: Basic FKOtaEWDFWEFRtaW4=
Lock-Token: <b257cb01-0a63-4841-abe6-744b95f41ae2-F>

Response: HTTP/1.1 204 No Content

Those are in the sequence they were sent. What I don't understand is
why the unlock method is happy with the lock token but the PUT method
fails. Any ideas where I'm going wrong?

Thanks,
Brad.

Reply via email to