Good pointer, I had overlooked this as the multiEC is implemented at the
later code. Thanks!
----- Original Message -----
From: "Jean-Francois Veillette" <jfveille...@videotron.ca>
To: "Cheong Hee (Gmail)" <chn...@gmail.com>
Cc: "Mark Ritchie" <mark.ritc...@mac.com>; "Chuck Hill"
<ch...@global-village.net>; <webobjects-deploy@lists.apple.com>
Sent: Thursday, July 16, 2009 8:51 PM
Subject: Re: Inaccurate active session count in JavaMonitor
There is a potential problem if logOnUser is an eo registered in an
editingContexte that is unlock() earlier in the method.
What you could do is :
public void terminate() {
String audit = null;
if (logOnUser != null)
audit = "User " + logOnUser.vName() + " is logging out.";
lockManager().unlock();
_multiECLockManager = null;
//RSP07042006
if (logOnUser != null)
this.auditLogWithType(audit, AuditHistory.OTHERS_TYPE);
super.terminate();
}
Le 09-07-16 à 05:35, Cheong Hee (Gmail) a écrit :
I just confirmed and checked my code that session.terminate() has
overriden as the following:
/**
* unlock ec when terminates.
*/
public void terminate() {
lockManager().unlock();
_multiECLockManager = null;
//RSP07042006
if (logOnUser != null)
this.auditLogWithType("User " + logOnUser.vName() + " is
logging out.", AuditHistory.OTHERS_TYPE);
super.terminate();
}
I will need to confirm if the application.activeSessionCount() printout
against JavaMonitor and see if the count is tally upon session time out.
My current timeout has set to -WOSessionTimeOut as 90. In fact, when I
did a proper log out, the count is reduced in JavaMonitor. Thanks all
and will try it out with code given.
----- Original Message ----- From: "Mark Ritchie" <mark.ritc...@mac.com
>
To: "Chuck Hill" <ch...@global-village.net>
Cc: "Cheong Hee (Gmail)" <chn...@gmail.com>;
<webobjects-deploy@lists.apple.com
>
Sent: Thursday, July 16, 2009 4:56 PM
Subject: Re: Inaccurate active session count in JavaMonitor
On 15-Jul-09, at 9:21 AM, Chuck Hill wrote:
The memory usage stats are meaningless, but the active session count
has been accurate in my experience. I suspect that your code has bugs
in it that are preventing session termination. Get a thread dump and
see if you have deadlocked threads.
This is my experience as well. The count of currently active sessions
is pretty important to management of deployed applications.
Perhaps you've overridden session.terminate() and forgotten to call
super.terminate()?
Or perhaps, as Chuck so wisely points out, it's some other problem with
your code.
Personally, I would use jdb to intercept what's happening when a
session terminates.
Alternatively, you could add code like this to your Session.java:
public void terminate() {
// dump a backtrace when the session is terminated
RuntimeException e = new RuntimeException();
e.printStackTrace();
// show the before and after count of the active session count from
WOApplication
NSLog.debug.appendln("before activeSessionCount = " +
WOApplication.application().activeSessionsCount());
super.terminate();
NSLog.debug.appendln("after activeSessionCount = " +
WOApplication.application().activeSessionsCount());
}
OTOH, it could be some weirdness with your installation...
Try building and deploying a new project with the terminate code above
and launch it with -DWOSessionTimeOut=5
Then connect to the instance, see the home page, then wait and watch to
see if the session times out.
Good Luck!
Mark
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-deploy mailing list (Webobjects- dep...@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-deploy/jfveillette%40videotron.ca
This email sent to jfveille...@videotron.ca
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-deploy mailing list (Webobjects-deploy@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-deploy/archive%40mail-archive.com
This email sent to arch...@mail-archive.com