Another possibility:
The session id is written to an encrypted string that is sent back when you
click a button or href on the displayed page. Under some circumstances the
string will be omitted (if you are doing stuff manually) or clobbered
(there have been length issues with IE). ND relies on this session ID to
fetch the right session objects from the cache (persistence engine). If
the session ID is not returned, ND will create a new session, and, of
course, if you ask for any session object, it will be null for the new session.
You might want to put in some diagnostic messages that dump out the session
id at the beginning of web events, to make sure you have the expected
continuity.
-- Curt Springer, Team ND
At 05:11 AM 9/14/99 -0400, Donald MacDonald wrote:
>No, currently there is nowhere in the code where we ever set a user session
>object to NULL. The problem seems to occur only intermitantly, and the session
>object should never be set to null.
>An example is I have a report which I do a database lookup to populate, I also
>query a session object to get the company no of the current user so I can
>limit
> the data returned to only records which pertain to this company. This report
>will normally work fine, the correct company no is returned from the session
>object as expected. If, I try and reload this screen occasionally the script
>will fall over, with a null pointer exception which I assume is caused by
>accessing an empty session object. But if I reload again it may work, it seems
>to be arbitrary whether the session object is returned or not.
>I think Curt's description of the problem matches exactly, the idea ofseparate
> project graphs. What I need to discover is how to change my code to use the
>correct session data whatever project graph is currently used and
>regardless of
>whether there are more than one person logged in at one time.
>
>Regards,
>Donald MacDonald
>*** Reply to note of 09/13/99 18:28
>To: DMACDO10--FORDMAIL Donald MacDonald
>
>From: Curt Springer
>Subject: Re: [ND] Session Objects lost after migration from NT -> Solaris
>
>From: "Curt Springer"<[EMAIL PROTECTED]>
>
>Did Janet's suggestion solve your problem?
>--Curt
>
> >Hi Donald,
> >
> >
> >Yes, when we move our Windows code to Unix, we often discover setting a SO's
> >value to null is OK to do on Windows, but not on Unix--we get the bad
> session
> >error. So to fix it....say in the case of a String in a SO, where we were
> >setting it to a null, we set it to an empty string instead.
> >
> >
> >Janet
> >
>
>
>At 12:03 PM 9/13/99 -0400, you wrote:
> >That sounds exactly what I am experiencing, the big question is ... how can
> >this fixed? Is the problem in my code (and therefore in the system
> design) or
> >will it be inthe way that the application server has been
> >configured on the unix box?
> >
> >Regards,
> >Donald MacDonald
> >*** Reply to note of 09/13/99 10:45
> >To: DMACDO10--FORDMAIL Donald Macdonald
> >
> >From: Curt Springer
> >Subject: Re: [ND] Session Objects lost after migration from NT -> Solaris
> >
> >From: "Curt Springer"<[EMAIL PROTECTED]>
> >cc: [EMAIL PROTECTED]
> >
> >My first guess would be that somehow or other you have hit a version of the
> >infamous (and often discussed) ND "session bleed". Your ND server has one
> >or more sets of your ND objects, called project graphs. Each session is
> >given exclusive access to one project graph during a web event. During a
> >subsequent web event, the session might get the same project graph, or
> >another one.
> >
> >You typically develop in an environment with one project graph, and one
> >active session at a time. Project design flaws are hidden until you move
> >the code to a situation where you have either or both of:
> >-- One project graph used in succession by two different sessions
> >-- One session given different project graphs in two successive web events.
> >
> >-- Curt Springer, Team ND
> >
> >At 01:54 AM 9/13/99 -0700, Donald Macdonald wrote:
> >
> > >I have developed a system on NT and migrated the code to the test
> > >environment which
> > >is a Sun solaris box. I am now experiencing problems with the session
> > >objects that I
> > >use within my code.
> > >
> > >For most of the time the system will perform as expected with the correct
> > >session
> > >objects returned in the page calls. Occassionaly though I will get a NULL
> > >POINTER
> > >ERROR when the session object does not now contain a value. If I hit the
> > >back button
> > >on the browser and then re-execute the code it will more often than not
> > >work correctly.
> > >I have also experienced the incorrect session data being returned during a
> > >call so that
> > >I will switch to a different user.
> > >
> > >Is there some configuartion problem within my app server?
> > >
> > >Has anyone else suffered simliar problems after migration?
> > >
> > >_________________________________________________________________________
> > >
> > >For help in using, subscribing, and unsubscribing to the discussion
> > >forums, please go to: http://www.netdynamics.com/support/visitdevfor.html
> > >
> > >For dire need help, email: [EMAIL PROTECTED]
_________________________________________________________________________
For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html
For dire need help, email: [EMAIL PROTECTED]