|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atlassian.bamboo.filter.AccessLogFilter
public class AccessLogFilter
Logs JIRA username and request URL via log4j. See http://confluence.atlassian.com/display/JIRA/User+access+logging
Constructor Summary | |
---|---|
AccessLogFilter()
|
Method Summary | |
---|---|
void |
destroy()
Does nothing |
void |
doFilter(javax.servlet.ServletRequest servletRequest,
javax.servlet.ServletResponse servletResponse,
javax.servlet.FilterChain chain)
Creates logs if INFO logging level is set and URL is "interesting" according to isInterestingUrl(String) . |
protected java.lang.String |
getEndText(java.lang.String startText,
long memDiff,
long timeDiff)
|
protected java.lang.String |
getStartText(java.lang.String url,
javax.servlet.http.HttpServletRequest request,
long startMem)
|
void |
init(javax.servlet.FilterConfig filterConfig)
Does nothing but prints INFO log message |
protected boolean |
isInterestingUrl(java.lang.String url)
Returns true if the given URL is of our interest. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AccessLogFilter()
Method Detail |
---|
public void init(javax.servlet.FilterConfig filterConfig) throws javax.servlet.ServletException
init
in interface javax.servlet.Filter
filterConfig
- not used
javax.servlet.ServletException
- not thrownpublic void doFilter(javax.servlet.ServletRequest servletRequest, javax.servlet.ServletResponse servletResponse, javax.servlet.FilterChain chain) throws java.io.IOException, javax.servlet.ServletException
isInterestingUrl(String)
.
doFilter
in interface javax.servlet.Filter
servletRequest
- requestservletResponse
- responsechain
- filter chain
java.io.IOException
- if another filter in the filter chain throws it
javax.servlet.ServletException
- if another filter in the filter chain throws itprotected java.lang.String getStartText(java.lang.String url, javax.servlet.http.HttpServletRequest request, long startMem)
protected java.lang.String getEndText(java.lang.String startText, long memDiff, long timeDiff)
protected boolean isInterestingUrl(java.lang.String url)
url
- url to check
public void destroy()
destroy
in interface javax.servlet.Filter
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |