web stat support

This commit is contained in:
wenshao
2012-08-14 14:58:15 +08:00
parent 476d68aad8
commit 36eeac3f2a
@@ -132,8 +132,10 @@ public class WebStatFilter implements Filter {
}
if (uriStat == null) {
if (responseWrapper.getStatus() == HttpServletResponse.SC_NOT_FOUND) {
uriStat = webAppStat.getURIStat("error_404", true);
int status = responseWrapper.getStatus();
if (status == HttpServletResponse.SC_NOT_FOUND) {
String errorUrl = contextPath + "/error_" + status;
uriStat = webAppStat.getURIStat(errorUrl, true);
} else {
uriStat = webAppStat.getURIStat(requestURI, true);
}