tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject JSPs, Servlets, Tomcat, IE and evil page caching behavior
Date Tue, 02 May 2000 18:18:36 GMT

Hi all,

Thought I would pass this on in case it isn't obvious to anyone else.

I have a JSP that produces data from a session bean, and uses a servlet to
adjust the state of the bean for navigation purposes.  The servlet either
returns an error page or returns the original JSP page.

Some combination of IE and Tomcat is causing some interesting page cacheing
behavior.  I had IE set to check for a new version of a page automatically.
When my session timed out, the button (i.e. URL) that triggered the error
message (generated from the servlet for the moment) produced a page that
did not have the no-cache meta tag (<META HTTP-EQUIV="Pragma" CONTENT
="no-cache">).   Reloading the JSP that starts the sequence caused a new
bean to be created, but the fact that that URL produced that piece of HTML
was locked into the IE cache, and it either did not check for new content,
or did and didn't seem to find it.

When I clicked the button which directed the browswer to run my navigation
servlet, I automatically got the error page, and the request was never sent
to the servlet itself.  Since the error page says it can't find the session
bean, you can imagine the results were a bit misleading...

I now have expired IE's cache and set it to always check for new content.
My example is working again. :)

I don't know if this is a bug with IE, a bug with Tomcat, both or neither.

John Robinson
Technical Architect
Knowledge House Inc.
5670 Spring Garden Road
Suite 200
Halifax, Nova Scotia
Canada B3J 1H6
902.429.1375 Tel
902.429.2858 Fax
902.490.2936 Direct

View raw message