Thursday, December 16, 2010

How to split a log file in tomcat

Source : http://jameslhf.blogspot.com/2010/03/how-to-split-log-file-in-tomcat.html

Tomcat log file splitter procedure:

1. Replace tomcat-juli inside bin\

2. Copy commons-logging-1.1.1, log4j.jar, and tomcat-juli-adapters to lib directory

3. Change log4j.p file in lib

4. Delete logging.properties in conf directory

Reading web-page made easy using JSP

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jstl/core_rt" prefix="c"%>
<html>
    <body>
        <c:import url="http://www.yahoo.com" var="newstuff"/>
        <c:out value="${newstuff}"/>
    </body>
</html>

It gives the content of the page into a variable called newstuff…

Friday, December 3, 2010

HttpWatch

HTTPWatch is a tool which can be used to check the HTTP traffic triggered when we access a web page. It can be used for debugging. Mostly all web applications make extensive use of the HTTP protocol (or HTTPS). HTTPWatch integrates with Internet Explorer and Firefox browsers. It also supports non-interactive examination of HTTP data wherein we can even examine log files that our customers and suppliers have recorded. It gives information regarding the URL, methods used (GET/POST), parameters passed etc.