You can implement onException() to catch exceptions thrown from page event handlers (see http://tapestry.apache.org/tapestry5.1/guide/event.html), or, though I know you don't like this, for handling known exceptions in a more generic manner you could use Tynamo's tapestry-exceptionpage module (http://tynamo.org/tapestry-exceptionpage+guide) - the module handles ajax requests as well.
Kalle On Tue, Jul 20, 2010 at 8:32 PM, Paul Stanton <p...@mapshed.com.au> wrote: > We have an ajax intensive project for which we need to better handle > problems such as session timeouts. > > Most of our ajax event handlers will return a MultizoneUpdate, and currently > will run into a NullPointerException if the session has timed out. > > Instead what I'd like these listeners to do is either forward to an error > page (ie session timed out page) or attempt to reload the current page. > > I'd also prefer to not have to implement this for every listener, but > utilise 'onActivate' so that I don't need to copy and paste code into every > event listener. > > Does anyone have any tips for achieving this? > > p. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org