Application activeSessionCount() question
Application activeSessionCount() question
- Subject: Application activeSessionCount() question
- From: Michael Halliday <email@hidden>
- Date: Mon, 13 Jan 2003 12:59:13 -0500
Hey everyone,
This might be a really dumb question and it might not be...not sure.
I'm fairly new to webobjects development but have picked it up rather
quickly. I was having a problem with locking an editing context which
led me to start debugging some of my application level code. I added
the following line to my application.java in my awake() method:
System.out.println( activeSessionsCount());
It seems that with every single request that I make a new session is
created. I thought this was rather strange so I created a brand new
web app with a single page and I added this:
public WOSession createSessionForRequest(WORequest request) {
WOSession session = super.createSessionForRequest(request);
System.out.println("Application: new session created: " +
session);
return session;
}
to my Application.java to see exactly what was going on. And every
time I refreshed this simple page I got a new session created. I guess
my question would be is this normal? For a new session to be created
with every request-response loop call? Does it not kind of defeat the
purpose of the activeSessionsCount() method?
I also tested this with some of the examples that came with the
devtools (including the HelloWorld app) and the same thing happens.
I'm running WO 5.2. Any comments would be appreciated.
Thanks,
Michael.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.