Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.0
-
None
Description
At JRoller, we've modified RefererFilter.java to check the user-agent and exclude certain spiders from the dayhits. Our list is currently anything with slurp, bot, or java in the user-agent. It helps to give a much better picture of the actual hits. The following lines were added to RefererFilter around line 77:
// Check the user agent, just ignore counts for dayhits.
String useragent = request.getHeader("User-Agent");
if (useragent != null && !"".equals(useragent) && useragent.indexOf("slurp") != -1 && useragent.indexOf("bot") != -1 && useragent.indexOf("java") != -1) {
if (mLogger.isDebugEnabled())
} else {