R
richard.anderson970
I'm having a rather perplexing issue that I hope you'll be able to help
me out with. I have an application comprised of a number of servlets
that are meant to be accessed by wireless devices. The issue I'm
having goes as such:
I have 2 servlets: Servlet1 and Servlet2. Users will always access the
application by going through Servlet1. In Servlet1, the service()
method will identify what phone they're using and create a Device
object that should be used session wide for identification of the
device. This done with the following:
request.getSession().setAttribute("device", device);
However, when I access Servlet2, and attempt to get the device object,
like so:
request.getSession().getAttribute("device");
I notice the the object is null. If I print out the session ids at
various stages, the session id in Servlet2 changes from Servlet1. When
I access the same servlets, from a web browser, I notice that the
session ids do not change, and I'm able to access the device object.
Is there something else I should be sending with the phones to maintain
state? I've attempted tacking on ;JSESSIONID=<session id> but this
does nothing. I don't believe there's a way to lookup a session by
session id. Can anyone offer assistance in this matter?
Thanks,
Rich
me out with. I have an application comprised of a number of servlets
that are meant to be accessed by wireless devices. The issue I'm
having goes as such:
I have 2 servlets: Servlet1 and Servlet2. Users will always access the
application by going through Servlet1. In Servlet1, the service()
method will identify what phone they're using and create a Device
object that should be used session wide for identification of the
device. This done with the following:
request.getSession().setAttribute("device", device);
However, when I access Servlet2, and attempt to get the device object,
like so:
request.getSession().getAttribute("device");
I notice the the object is null. If I print out the session ids at
various stages, the session id in Servlet2 changes from Servlet1. When
I access the same servlets, from a web browser, I notice that the
session ids do not change, and I'm able to access the device object.
Is there something else I should be sending with the phones to maintain
state? I've attempted tacking on ;JSESSIONID=<session id> but this
does nothing. I don't believe there's a way to lookup a session by
session id. Can anyone offer assistance in this matter?
Thanks,
Rich