Hey Nick,
Actually I always run inprod mode. Please look at me
newest question as I have distilled it down further. It
seems as though any renegade form request can be submitted
at any time and it attempts to be handled within the
current session even if it was rendered in a previous one.
Can you help with that one at all?
Thanks
doug
Hi Douglas.
I presume you are using
-Dorg.apache.tapestry.disable-caching=true
or similar for development.
Try running your app without this, i.e. in production
mode.
I've seen exceptions in dev mode that don't happen in
production.
Cheers,
Nick.
LOCHART,DOUGLAS E wrote:
Geoff,
I changed our logout procedure to match yours and then tried the same excerice
and got the same Exception.
Doug
-------------------
here's how we implement logout in a listener - works for us..
public void logoutUser(IRequestCycle cycle) {
getPage().getEngine().setVisit(null);
try {
HttpSession session = cycle.getRequestContext().getSession();
if (session != null) {
session.invalidate();
}
} catch (IllegalStateException ex) {
}
// make sure to include the application context in effect in the
redirection URL
String contextPath =
cycle.getRequestContext().getRequest().getContextPath();
throw new RedirectException(contextPath +
"/app?service=page/Logout");
}
On 8/31/05, LOCHART,DOUGLAS E <[EMAIL PROTECTED]> wrote:
Geoff,
When I looked over the Stack Trace it appears as though
the session this page rendering belonged too is alive. In
the tapestry Exception page it says that Session.isNew()
is NO. Then it contniues the process until it gets into
the Visit Object which I clear during Logout.
Could it be that my logout mechanism is not working? I
used to do this:
Visit visit = (Visit)getVisit();
visit.clear();
try {
((IEngineServiceView)getEngine()).restart( cycle );
}catch(Exception e) {
_logger.warn("Logout Exception: Ignoring ... ",e);
}
Then I read a posting that you should not do this in a
listener and they proposed using the restart service
directly. I could not find an example of this so I tried
the following:
Visit visit = (Visit)getVisit();
visit.clear();
IEngineService pageService =
cycle.getEngine().getService(Tapestry.RESTART_SERVICE);
String pageName =
cycle.getPage().getExtendedId();
String redirector = pageService.getLink(cycle,
null, new String[0]).getURL();
throw new RedirectException(redirector);
I now do this. Both seem to work for me for the most
part. But the first time I saw this problem It was an
overnight thing and the Logout code was not involved. The
Session should have timed out. I do NOT have any fancy
ajax stuff that pings to keep the session alive either.
Doug
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-- The Spindle guy. http://spindle.sf.net Get help with Spindle:
http://lists.sourceforge.net/mailman/listinfo/spindle-user Announcement Feed:
http://www.jroller.com/rss/glongman?catname=/Announcements Feature Updates:
http://spindle.sf.net/updates
--------------------------------------------------------------------- To
unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL
PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail:
[EMAIL PROTECTED]
For additional commands, e-mail:
[EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]