[ https://issues.apache.org/jira/browse/HADOOP-4530?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hairong Kuang updated HADOOP-4530: ---------------------------------- Attachment: fsckError2.patch The patch incorporates Konstantin's comments. Thank Konstantin for helping me figure out the way to test the failure case. In addition, it makes sure that the DFS cluster gets shutdown in case of a failure in the testFsckCorrupt. > In fsck, HttpServletResponse sendError fails with IllegalStateException > ----------------------------------------------------------------------- > > Key: HADOOP-4530 > URL: https://issues.apache.org/jira/browse/HADOOP-4530 > Project: Hadoop Core > Issue Type: Bug > Components: dfs > Affects Versions: 0.18.1 > Reporter: Koji Noguchi > Assignee: Hairong Kuang > Attachments: fsckError.patch, fsckError1.patch, fsckError2.patch > > > When looking at HADOOP-4526, I tried using sendError at line:53. > {code:title=FsckServlet.java|borderStyle=solid} > _ > 49 } catch (IOException ie) { > 50 StringUtils.stringifyException(ie); > 51 LOG.warn(ie); > 52 String errMsg = "Fsck on path " + pmap.get("path") + " failed."; > 53 response.sendError(HttpServletResponse.SC_GONE, errMsg); > 54 throw ie; > 55 } > {code} > However, it always failed with > {noformat} > 2008-10-27 22:39:07,359 WARN /: /fsck?path=%2Fuser: > java.lang.IllegalStateException: Committed > at > org.mortbay.jetty.servlet.ServletHttpResponse.resetBuffer(ServletHttpResponse.java:212) > at > org.mortbay.jetty.servlet.ServletHttpResponse.sendError(ServletHttpResponse.java:375) > at org.apache.hadoop.dfs.FsckServlet.doGet(FsckServlet.java:54) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) > at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427) > at > org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475) > at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567) > at org.mortbay.http.HttpContext.handle(HttpContext.java:1565) > at > org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635) > at org.mortbay.http.HttpContext.handle(HttpContext.java:1517) > at org.mortbay.http.HttpServer.service(HttpServer.java:954) > at org.mortbay.http.HttpConnection.service(HttpConnection.java:814) > at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:981) > at org.mortbay.http.HttpConnection.handle(HttpConnection.java:831) > at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:244) > at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:357) > at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534) > {noformat} > And client wasn't seeing the error. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.