I upgraded Monday from apache+jserv to Apache 1.3+Tomcat 3.2.1+mod_jk,
and I'm experiencing some bizarre problems with some of my webapps. One
in particular looks like this:
index.jsp
-----------
<%@ page import="java.sql.*" %>
<%
if (request.getRemoteAddr().equals("..."))
{
response.sendRedirect("http://10.1.1.6/same page");
// 10.1.1.6 is the internal ip address of the machine this page is
on
}
session.invalidate();
session = request.getSession(true);
session.set a bunch of attributes
%>
<form action=login.jsp method=post>
...
</form>
login.jsp
-----------
request.get some parameters
session.get a bunch of attributes
First of all, the response.sendRedirect puts the thing in an infinite
loop. This didn't happen when I was running jserv and no Tomcat. But I
comment that out, because I don't really know what it's there for
(security, I guess), but then I get weird session behavior. Apparently
the login.jsp is eschewing the session created in index.jsp and creating
its own session, which of course contains none of my special variables.
I cannot figure out why it would be doing this.
Grateful for any help,
Ben Carterette
[EMAIL PROTECTED]