Are you sure that the URLs (server names) used to access both the JSP and Servlet are the same? For example, if you access the jsp with http://www.site.com/my.jsp and access the servlet from the browser with http://localhost/my.jsp, you'll see exactly what you're describing below.
Can you give us some information about your setup? Browser based? Using cookies? URL rewriting? Do you have a webserver frontend (Apache/JK)? Source for jsp? How is the servlet hit (directly, from a form action)?
justin
At 12:21 PM 11/19/2002, you wrote:
Still zero responses... "ooh and it makes me wonder" Should I provide further details? Any comments would help, I'm just seeking clues not
necessarily a solution.
Thanks!
-FB
On Tuesday, November 19, 2002, at 08:00 AM, [EMAIL PROTECTED] wrote:
I'm not sure if Tomcat 4.1.12 has something to do with the following problem. My client session id is seemingly not written to the implicit JSP request object. Below is a section of my catalina.out printout which shows this.
Two things to note:
1. The request object is indeed instantiated and is shipped to Tomcat with valid data. Otherwise I would not be able to see the From and To dates that are constructed from drop down widgets on the JSP.
2. I would expect the session ids to match. Is this assumption correct
JSP Session id: 3F6FC46A183303B69EC4E8097528159E
Request Session id: null
Servlet Session id: F8568A66D6EF4BE71AC8AD37FF0921C7
Servlet Session is New?: true
Is Requested Session is Valid? false
Is Requested Session from Cookie? false
Is Requested Session from URL? false
FromDate : Oct/10/2002
ToDate : Oct/19/2002
Here's the servlet code (nothing special here, as far as I can tell)
public void doGet(
HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException {
response.setContentType("text/html");
PrintWriter out = response.getWriter();
HttpSession session = request.getSession(true);
//HttpSession session = request.getSession();
session.setMaxInactiveInterval(60*30);
System.out.println("Request Session id: " + request.getRequestedSessionId() );
System.out.println("Servlet Active Session id: " + session.getId() );
System.out.println("Servlet Active Session new?: " + session.isNew() );
boolean rtrue = request.isRequestedSessionIdValid();
System.out.println("Is Requested Session Valid? " + rtrue );
boolean ctrue = request.isRequestedSessionIdFromCookie();
System.out.println("Is Requested Session from Cookie? " + ctrue );
boolean utrue = request.isRequestedSessionIdFromURL();
System.out.println("Is Requested Session from URL? " + utrue );
--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
