You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-user@jakarta.apache.org by Ali Naddaf <al...@naddaf.org> on 2007/03/27 22:25:43 UTC
400 bad request error
Hello everyone.
I just started using slide + slide-client and am running into a basic
issue that doesn't allow me go any further. I downloaded slide server
(binary, version 2.1) and dropped the war in my webapp directory of
tomcat (5.5.23). Then I was able to access the WebDAV file system using
my Windows explorer; I was be to drop a file there and get a file. So
that makes me think that the server side is working fine.
Then I downloaded the slide-webdav-client (2.1) and tried to run the
following code:
---------------------------------
public static void main(String[] args) {
try
{
HttpURL url = new HttpURL("http://localhost:8080/slide/files");
WebdavResource res = new WebdavResource(url);
File file = new File("C:/temp.zip");
res.putMethod(file);
res.close();
}
catch(Exception e) {
e.printStackTrace();
}
}
-------------------------------
but at the line that I am creating the webdav resource, it fails and on
the server log, I see the following error:
http-8080-Processor25, 27-Mar-2007 14:14:26, unauthenticated, PROPFIND,
400 "Bad Request", 0 ms, /files
and in my java code, the following stack:
--------------------------------
org.apache.commons.httpclient.HttpException
at
org.apache.webdav.lib.WebdavResource.propfindMethod(WebdavResource.java:3467)
at
org.apache.webdav.lib.WebdavResource.propfindMethod(WebdavResource.java:3423)
at
org.apache.webdav.lib.WebdavResource.setNamedProp(WebdavResource.java:967)
at
org.apache.webdav.lib.WebdavResource.setBasicProperties(WebdavResource.java:912)
at
org.apache.webdav.lib.WebdavResource.setProperties(WebdavResource.java:1894)
at
org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:1301)
at
org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:1320)
at
org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:1408)
at org.apache.webdav.lib.WebdavResource.<init>(WebdavResource.java:290)
at com.dawnatech.cyclops.webdav.WebDAVTest.main(WebDAVTest.java:16)
------------------------------------
Could someone please tell me what I am missing?
Many thanks,
Ali.
---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org