Hi BJ,

You have a jsp page which has the applet tag for ULC client. In the same jsp 
page you are passing on some toString of userinfo to be displayed in an 
alert on the client side. This userinfo is stored in the HTTPSession.

Then the ULC application is started and you get its HTTPSession and you find 
that it does not contain the USerInfo Object but This happens sometimes, at 
other times the session does have UserInfo object. Is this right?

Does this scenario happen for the same client machine or different client 
machines?

Are you using any kind of load balancing? Are your sessions sticky?

You can set the server side log level to FINEST and see whether ULC servlet 
is creating  new session  or not.


Thanks and regards,

Janak
-------------

From: [email protected] 
[mailto:[email protected]] On Behalf Of BJ Tenney
Sent: 16 August 2010 19:43
To: [email protected]
Subject: [ULC-developer] HttpSession does not contain all information all 
the time.

I am using ULC 2008
We have an embedded ULC application in our servlet based system.
Sometimes when calling ServletContainerContext.getHttpSession(); the 
HttpSession doesn't seem to contain all the same information as the jsp. 
for example, on the jsp I have the following code

------- jsp code  -----------------------
<script language="JavaScript">
  alert('<%=session.getAttribute("userinfo")%>');
</script>
<applet.....................>
</applet>
------------------------------------------
This alert always outputs and alerts:
alert('com.tomax.ewm.common.useri...@7ab825');

This jsp page serves up the ULC application.
---------------ulc application code -------
public void initialize() {
session = ServletContainerContext.getHttpSession();
fTimeCardsHelper = new TimeCardsHelper(session);
}
public TimeCardsHelper(HttpSession session2) {
this.session = session2;userInfo 
= (UserInfo)(session.getAttribute("userinfo"));
sessionID = userInfo.sessionID;
}
-----------------------------------------------

At times, the userInfo variable is null in the ulc application code, but is 
never null in the jsp.  Because of this, it is null it is throwing a 
NullPointerException at times.
Is there some reason the HttpSession would be different sometimes between 
the jsp and the ulc code?

BJ Tenney
Java Developer
Tomax Corporation
_______________________________________________
ULC-developer mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/ulc-developer

Reply via email to