apache/spark — pull request #163 by andrewor14 (2014-03-18 02:55:09+00:00)
Title: [SPARK-1265] Fix 404 error from Jetty 9 upgrade

We recently upgraded Jetty from v7.6.8 to v9.1.3. This introduced a 404 not found HTTP error when accessing the root of any UI.

The problem is that the existing code attaches two handlers to the root, one of which is a handler for static resources. In Jetty 9.1.3, we are no longer allowed to do this. Instead, we are supposed to use ResourceHandler rather than ServletContextHandler for serving static resources: http://stackoverflow.com/questions/10284584/serving-static-files-w-embedded-jetty.

Note that this means we can no longer apply filters to static resources, since our handler for static resources has no notion of servlets. This is largely not a big problem, since static resources are not specific to the application.