Hello,
We've been greatly enjoying migrating our WCM and commerce platform
to the Restlet API. We have a versioned filesystem historically
exposed via a WebDAV Servlet, which was reasonably straightforward to
adapt to Restlet.
One issue, however, seemed to require a patch to get past; the NRE
does not seem to respond in a compliant way to OPTIONS requests,
since the Allow: header is only included when
Status.CLIENT_ERROR_METHOD_NOT_ALLOWED. This causes trouble with
(the woefully rare) polite WebDAV clients that actually ask for
allowed methods prior to attempting to use them. Since OPTIONS is
part of the HTTP/1.1 specification and not just DAV specific, I think
support for this seems reasonable in core NRE.
I've had success with the following patch to
com.noelios.restlet.http.HttpServerConverter.java -- any chance of
committing it? Happy to open an issue for it if you concur it's
worthwhile. I imagine other converters might need similar surgery,
but we're only using the HttpServerConverter right now, so this is my
first priority!
In related matters ... I saw mention in the blog that full WebDAV
exposure is on the roadmap; if you need more resources to assist with
this, my team and I would be pleased to help; we have a lot of
practical experience coping with the behavior and misbehavior of the
myriad DAV user-agents out there.
Cheers,
- Rob
Index: .
===================================================================
--- . (revision 2129)
+++ . (working copy)
@@ -129,7 +129,9 @@
.getResponseHeaders();
if (response.getStatus().equals(
- Status.CLIENT_ERROR_METHOD_NOT_ALLOWED)) {
+ Status.CLIENT_ERROR_METHOD_NOT_ALLOWED) ||
+ response.getRequest().getMethod().equals(
+ Method.OPTIONS)) {
// Format the "Allow" header
StringBuilder sb = new StringBuilder();
boolean first = true;