Bug 1315936
Summary: | [GSS](6.4.z) Custom error page is ignored for 405 Method Not Allowed | ||||||
---|---|---|---|---|---|---|---|
Product: | [JBoss] JBoss Enterprise Application Platform 6 | Reporter: | Osamu Nagano <onagano> | ||||
Component: | RESTEasy, Web | Assignee: | Chao Wang <chaowan> | ||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Peter Mackay <pmackay> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | high | ||||||
Version: | 6.3.0 | CC: | bbaranow, bmaxwell, cdewolf, chaowan, jtruhlar, onagano, pmackay, weli | ||||
Target Milestone: | CR1 | ||||||
Target Release: | EAP 6.4.10 | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | Type: | Bug | |||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 1324261, 1339868 | ||||||
Attachments: |
|
Description
Osamu Nagano
2016-03-09 03:45:39 UTC
Created attachment 1134399 [details]
xxx.yyy.zzz.war
Hi, I'm very sorry that I forgot to attach the war file, xxx.yyy.zzz.war.
In JBossWeb, https://source.jboss.org/browse/JBossWeb/branches/7.5.x/src/main/java/org/apache/catalina/core/StandardHostValve.java?hb=true#to424 When http status code is 405, it will return immediately without finding any customer error page at line: /* Only look for error pages when isError() is set. * isError() is set when response.sendError() is invoked. This * allows custom error pages without relying on default from * web.xml. */ if (!response.isError()) return; I can see the custom error page for status code 405 once I comment out the "return;" $ curl -i http://localhost:8080/test/xyz/foo -X GET HTTP/1.1 405 Method Not Allowed Server: Apache-Coyote/1.1 Allow: POST, OPTIONS Accept-Ranges: bytes ETag: W/"117-1455094050000" Last-Modified: Wed, 10 Feb 2016 08:47:30 GMT Content-Type: text/html Content-Length: 117 Date: Thu, 10 Mar 2016 09:44:43 GMT <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>.</title> </head> <body>.<!-- J --></body> But, it seems this is an expected action when response.isError() value is false as comments above the codes. More investigation is needed here, and I add web as second component for this bugzilla. This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions Verified with EAP 6.4.10.CP.CR2 Retroactively bulk-closing issues from released EAP 6.4 cummulative patches. Retroactively bulk-closing issues from released EAP 6.4 cummulative patches. |