I now have all testcases passing except for th WebDAV testcases, as described below. I've created a new issue and attached a patch file with my proposed changes (note this also contains the fix for VFS-245):
https://issues.apache.org/jira/browse/VFS-266 What are the next steps from here? On Mon, Jun 22, 2009 at 2:43 PM, Vince Bonfanti <vbonfa...@gmail.com> wrote: > I fixed the HTTP failure by disabling the "welcome" page in welcome.conf (I > don't know if this is standard Apache configuration or something peculiar to > CentOS). All of the HTTP tests are now passing with my changes. > > For the WebDAV failure, this is what I see in the access_log file: > > 192.168.200.106 - - [22/Jun/2009:14:09:06 -0400] "PROPFIND > /vfstest/test-data/read-tests HTTP/1.1" 401 481 "-" "Jakarta-Commons-VFS" > 192.168.200.106 - vfsusr [22/Jun/2009:14:09:06 -0400] "PROPFIND > /vfstest/test-data/read-tests HTTP/1.1" 301 340 "-" "Jakarta-Commons-VFS" > > I think the 301 "Moved Permanently" response is expected when receiving a > request for a directory that doesn't end with "/". Isn't this what the > Apache server is supposed to do--send the client a redirect with the "/" > added to the end of the URL? To test this, I sent an HTTP GET request from > Firefox, and got the same results in the access_log file, except this time > the browser responded properly to the redirect: > > 192.168.200.106 - - [22/Jun/2009:14:36:56 -0400] "GET > /vfstest/test-data/read-tests HTTP/1.1" 301 340 "-" "Mozilla/5.0 (Windows; > U; Windows NT 6.0; en-US; rv:1.9.0.10) Gecko/2009042316 Firefox/3.0.10 (.NET > CLR 3.5.30729)" > 192.168.200.106 - - [22/Jun/2009:14:36:56 -0400] "GET > /vfstest/test-data/read-tests/ HTTP/1.1" 200 1676 "-" "Mozilla/5.0 (Windows; > U; Windows NT 6.0; en-US; rv:1.9.0.10) Gecko/2009042316 Firefox/3.0.10 (.NET > CLR 3.5.30729)" > > So I'm a bit puzzled, not being an expert on either WebDAV or Apache > configuration. It seems that the server is doing what it's supposed to, but > the client (VFS WebDAV provider) isn't responding properly. > > Again, any help is greatly appreciated. > > Vince > > > > On Sat, Jun 20, 2009 at 2:51 AM, Ralph Goers > <ralph.go...@dslextreme.com>wrote: > >> In both cases I would suggest enabling debugging for httpclient. It will >> give you a bunch of output to show what is really going on. But an error >> with "Moved Permanently" leads me to think something isn't right on your >> server. According to RFC 2616 vfs should not automatically redirect on a 301 >> status code. What do you see in the Apache logs? >> >> Ralph >> >> >> On Jun 19, 2009, at 2:33 PM, Vince Bonfanti wrote: >> >> I'm trying to run the HTTP and Webdav testcases without any of my changes >>> in >>> order to verify my test environment. I'm running on CentOS 5.3 with the >>> built-in Apache 2.2 server. I believe I've followed the instructions >>> properly, but I'm getting two errors. I'm going to give up for now and >>> try >>> again next week; in the mean time, if anyone can offer any insight on >>> these >>> failures I'd be very grateful. Thanks. >>> >>> Here's the HTTP failure: >>> >>> >>> ------------------------------------------------------------------------------- >>> Test set: org.apache.commons.vfs.provider.http.test.HttpProviderTestCase >>> >>> ------------------------------------------------------------------------------- >>> Tests run: 56, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 5.398 >>> sec >>> <<< FAILURE! >>> testRoot(org.apache.commons.vfs.test.ContentTests) Time elapsed: 0.023 >>> sec >>> <<< ERROR! >>> org.apache.commons.vfs.FileSystemException: Could not determine the type >>> of >>> file "http://vfsusr:*...@192.168.241.128/". >>> at >>> >>> org.apache.commons.vfs.provider.AbstractFileObject.getType(AbstractFileObject.java:450) >>> at >>> >>> org.apache.commons.vfs.provider.AbstractFileObject.exists(AbstractFileObject.java:424) >>> at >>> org.apache.commons.vfs.test.ContentTests.testRoot(ContentTests.java:109) >>> *Caused by: org.apache.commons.vfs.FileSystemException: HEAD method >>> failed >>> for "http://vfsusr:*...@192.168.241.128/".* >>> at >>> >>> org.apache.commons.vfs.provider.http.HttpFileObject.doGetType(HttpFileObject.java:92) >>> at >>> >>> org.apache.commons.vfs.provider.AbstractFileObject.getType(AbstractFileObject.java:441) >>> ... 32 more >>> >>> Here's the Webdav failure: >>> >>> >>> ------------------------------------------------------------------------------- >>> Test set: >>> org.apache.commons.vfs.provider.webdav.test.WebdavProviderTestCase >>> >>> ------------------------------------------------------------------------------- >>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.56 sec >>> <<< >>> FAILURE! >>> junit.framework.testsu...@1e152c5 Time elapsed: 0 sec <<< ERROR! >>> org.apache.commons.vfs.FileSystemException: Could not determine the type >>> of >>> file "webdav://vfsusr:*...@192.168.241.128/vfstest/test-data/read-tests". >>> at >>> >>> org.apache.commons.vfs.provider.AbstractFileObject.getType(AbstractFileObject.java:450) >>> at >>> >>> org.apache.commons.vfs.provider.AbstractFileObject.exists(AbstractFileObject.java:424) >>> at >>> >>> org.apache.commons.vfs.test.AbstractTestSuite.setUp(AbstractTestSuite.java:173) >>> at junit.extensions.TestSetup$1.protect(TestSetup.java:18) >>> at junit.framework.TestResult.runProtected(TestResult.java:124) >>> at junit.extensions.TestSetup.run(TestSetup.java:23) >>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >>> at >>> >>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >>> at >>> >>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >>> at java.lang.reflect.Method.invoke(Method.java:597) >>> at >>> >>> org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.java:213) >>> at >>> >>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140) >>> at >>> >>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127) >>> at org.apache.maven.surefire.Surefire.run(Surefire.java:177) >>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >>> at >>> >>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >>> at >>> >>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >>> at java.lang.reflect.Method.invoke(Method.java:597) >>> at >>> >>> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345) >>> at >>> >>> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009) >>> *Caused by: org.apache.commons.vfs.FileSystemException: Unknown message >>> with >>> code "Moved Permanently".* >>> at >>> >>> org.apache.commons.vfs.provider.webdav.ExceptionConverter.generate(ExceptionConverter.java:88) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.ExceptionConverter.generate(ExceptionConverter.java:41) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.execute(WebdavFileObject.java:367) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.getProperties(WebdavFileObject.java:442) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.getProperties(WebdavFileObject.java:417) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.getProperty(WebdavFileObject.java:410) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.getProperty(WebdavFileObject.java:402) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.isDirectory(WebdavFileObject.java:382) >>> at >>> >>> org.apache.commons.vfs.provider.webdav.WebdavFileObject.doGetType(WebdavFileObject.java:112) >>> at >>> >>> org.apache.commons.vfs.provider.AbstractFileObject.getType(AbstractFileObject.java:441) >>> ... 19 more >>> >>> >> >