Improving LiveTime Performance with Tomcat 7.0

Tomcat Performance TuningLiveTime 6.5 now ships preconfigured with Tomcat 7.0. One of the great advantages of Tomcat 7.0 is that it has been well tuned for performance already (also supporting the new Servlet 3.0 specification and asynchronous request processing) and can cope with thousands of users very easily. However, exposing LiveTime to the general Internet we often see a very large increase in apparent users, growing to 10′s of thousands in a very short time, that can take hours to drop off.

The problem is that web bots and search engines continually crawl the public knowledge base of LiveTime and create new connections for every page they access. This can consume valuable resources that are much better used for servicing real customers.

Rather than simply blocking these bots a better approach is available in Tomcat 7.0 through the use of valves. Valves are basically small libraries of services that can be enabled within Tomcat to perform a number of low level tasks.

Using the new Crawler Session Manager Valve of Tomcat 7.0 we have been able to reduce session counts by almost 95%, similar to what has been seen by others users.


To configure the Crawler Valve simply edit the server.xml file on your Tomcat Server and add the following line to your engine block as follows.

 <Engine name="Catalina" defaultHost="localhost">

	  <Valve className="org.apache.catalina.valves.CrawlerSessionManagerValve" 
	  		 crawlerUserAgents=".*[bB]ot.*|.*Yahoo! Slurp.*|.*Feedfetcher-Google.*" 

Next restart Tomcat and monitor the sessions on the LiveTime System reports page. You will see a significant drop in session count and corresponding increase in available resources and performance. This has already been done for you in LiveTime and Novell Service Desk 6.5.


Crawler Session Manager Valve