• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

urgent - session null

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
In a application; i have a JSP page which contains a link which points to servlet which serves the image.
Now the problem is when a servlet is called session is null. I am not able to figure out why i am getting the session as null. I am using encodeURL to encode the link (in order to append session id). Also this problem is not consistent. Sometimes it works and other times i get session as null.
Please help.
Regards,
Nitin
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It sounds like your JSP and the servlet that serves the image are not in the same web application so the session is not shared.
Bill
 
Nitin Gogia
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
They are a part of same web application. Also i mentioned that it works sometimes but most of the times it gives session is null. Therefore difficult to trace.
 
Ranch Hand
Posts: 645
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is chance that session is expiring by time
you get to image servlet....
Praful
[ March 12, 2003: Message edited by: Praful Thakare ]
 
reply
    Bookmark Topic Watch Topic
  • New Topic