You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Dirk Forchel <di...@exedio.com> on 2011/10/06 09:32:00 UTC

Wicket 1.5 and ExceptionHandling

In Wicket 1.4 we used our custom RequestCycle and the onRuntimeException
method to add/change the exception handling. How do we change the exception
handling in Wicket 1.5?

The Migration Guide says:

Exception handling

In Wicket 1.4 it was needed to extend
org.apache.wicket.RequestCycle.onRuntimeException(Page, RuntimeException).
Wicket 1.5 gives even better control, by overriding
org.apache.wicket.Application.newExceptionMapper() it is possible to change
even the default processing of error pages.
For information on how the request cycle handles exceptions see RequestCycle
in Wicket 1.5 for more information

But with Wicket 1.5.1 it is not possible to override the
newExceptionMapper() method. What is the preffered way now?

--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-1-5-and-ExceptionHandling-tp3877300p3877300.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket 1.5 and ExceptionHandling

Posted by Martin Grigorov <mg...@apache.org>.
I just updated the migration page.
The page for RequestCycle looks clear to me.
Feel free to improve it, the wiki is editable by everyone, you just
need to create an account.

On Thu, Oct 6, 2011 at 10:43 AM, vineet semwal
<vi...@gmail.com> wrote:
> you can create ExceptionListener which implements
> IRequestCycleListener ,define its onexception method
> and in your webapplication init you can do
> getRequestCycleListeners().add(new ExceptionListener())
>
> On Thu, Oct 6, 2011 at 1:02 PM, Dirk Forchel <di...@exedio.com> wrote:
>> In Wicket 1.4 we used our custom RequestCycle and the onRuntimeException
>> method to add/change the exception handling. How do we change the exception
>> handling in Wicket 1.5?
>>
>> The Migration Guide says:
>>
>> Exception handling
>>
>> In Wicket 1.4 it was needed to extend
>> org.apache.wicket.RequestCycle.onRuntimeException(Page, RuntimeException).
>> Wicket 1.5 gives even better control, by overriding
>> org.apache.wicket.Application.newExceptionMapper() it is possible to change
>> even the default processing of error pages.
>> For information on how the request cycle handles exceptions see RequestCycle
>> in Wicket 1.5 for more information
>>
>> But with Wicket 1.5.1 it is not possible to override the
>> newExceptionMapper() method. What is the preffered way now?
>>
>> --
>> View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-1-5-and-ExceptionHandling-tp3877300p3877300.html
>> Sent from the Users forum mailing list archive at Nabble.com.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
>
>
>
> --
> thank you,
>
> regards,
> Vineet Semwal
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket 1.5 and ExceptionHandling

Posted by vineet semwal <vi...@gmail.com>.
you can create ExceptionListener which implements
IRequestCycleListener ,define its onexception method
and in your webapplication init you can do
getRequestCycleListeners().add(new ExceptionListener())

On Thu, Oct 6, 2011 at 1:02 PM, Dirk Forchel <di...@exedio.com> wrote:
> In Wicket 1.4 we used our custom RequestCycle and the onRuntimeException
> method to add/change the exception handling. How do we change the exception
> handling in Wicket 1.5?
>
> The Migration Guide says:
>
> Exception handling
>
> In Wicket 1.4 it was needed to extend
> org.apache.wicket.RequestCycle.onRuntimeException(Page, RuntimeException).
> Wicket 1.5 gives even better control, by overriding
> org.apache.wicket.Application.newExceptionMapper() it is possible to change
> even the default processing of error pages.
> For information on how the request cycle handles exceptions see RequestCycle
> in Wicket 1.5 for more information
>
> But with Wicket 1.5.1 it is not possible to override the
> newExceptionMapper() method. What is the preffered way now?
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-1-5-and-ExceptionHandling-tp3877300p3877300.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>



-- 
thank you,

regards,
Vineet Semwal

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org