File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes IE 5.5 patch caused session.isNew() to be true always Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "IE 5.5 patch caused session.isNew() to be true always" Watch "IE 5.5 patch caused session.isNew() to be true always" New topic

IE 5.5 patch caused session.isNew() to be true always

Jes Sie
Ranch Hand

Joined: Jul 24, 2001
Posts: 188
Just wanna share an experience here: -
I've done various tests and find out that the session ID is the same as they traverse across pages. But, the session.isNew() is always "true". For example: -

BigDecimal bg = new BigDecimal("123");
Object obj=session.getAttribute("bg");
// test
System.out.println("Session is new");

I've placed a similar check on its following JSP page. And it's new. This is actually not an error as the Servlet specs did say that isNew() will always return true till the browser has returned to the server.
From the JSP, I check its following Action (perform method) session....again is new! No, this is the problem. How can this be? Something is wrong, huh?
The interesting thing is why it used to work? What's the diff between today and the last time? Ahhhh...I've updated my IE 5.5 to run the latest patch from Microsoft.
Therefore, I've to download another browser to test. I used True works. This proof that Struts and your component is clean and only IE patch sucks.
I think you should put this mail as one of your support knowledge base.

Gee...this is annoying. I hate Microsoft!!!

Thank you.<br /> <br />- Jess Sie<br /> <a href="" rel="nofollow"></a>
Jessica Sant

Joined: Oct 17, 2001
Posts: 4313

Couple questions:
1- Are you sure you have cookies turned ON in IE 5.5? -- You won't be able to maintain session without any cookies.
2- So on each page you get session.isNew() == true -- but can you store on object in session on page1.jsp and retrieve the object in page2.jsp? or has the object disappeared?

- Jess
Blog:KnitClimbJava | Twitter: jsant | Ravelry: wingedsheep
I agree. Here's the link:
subject: IE 5.5 patch caused session.isNew() to be true always
It's not a secret anymore!