You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by jchappelle <jc...@4redi.com> on 2012/08/15 18:40:42 UTC

IExceptionMapper to notify support of errors

I have written an IExceptionMapper that notifies our support team if an
unexpected exception occurs. It will redirect the user to our ErrorPage and
in the ErrorPanel.onBeforeRender I send a notification via email in a new
Thread. This mostly works except we are getting several false positives.
What I mean is that the user never sees the ErrorPanel and continues to
work. So our support team doesn't know if the user really notices an error
or not.

Here are the things that I don't understand about this behavior. If my
notification code is in the onBeforeRender of my ErrorPanel, then how does
this code execute and the user never see the panel? Also, we keep getting
the following exceptions (it seems to happen where we have a tinymce in a
form). The first one we see in development only but the second we see in
production only. However, they both seem to be around
org.apache.wicket.request.mapper.AbstractComponentMapper.getPageClass. The
second generates a notification and the user never sees the ErrorPanel. 

*Error seen in development environment:*

*Error seen in production*




--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/IExceptionMapper-to-notify-support-of-errors-tp4651251.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: IExceptionMapper to notify support of errors

Posted by jchappelle <jc...@4redi.com>.
I'll do the timer then. Thanks for your help Igor.



--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/IExceptionMapper-to-notify-support-of-errors-tp4651251p4651256.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: IExceptionMapper to notify support of errors

Posted by Igor Vaynberg <ig...@gmail.com>.
not really. like i said, if this happens during a resource url then
the browser will never show the response.
your best bet is to use a timer or any other callback that gets
triggered via javascript, so you know the user sees the error panel.

-igor

On Wed, Aug 15, 2012 at 10:22 AM, jchappelle <jc...@4redi.com> wrote:
> Thanks for the quick response Igor.
>
> Are there any callback methods in Panel that will allow me to put my
> notification code and guarantee that it will be rendered to the user? Worst
> case I could add a timer behavior to the panel that makes a callback to the
> server and executes the notification, but I don't really like that solution.
>
> Josh
>
>
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/IExceptionMapper-to-notify-support-of-errors-tp4651251p4651254.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
>

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


Re: IExceptionMapper to notify support of errors

Posted by jchappelle <jc...@4redi.com>.
Thanks for the quick response Igor.

Are there any callback methods in Panel that will allow me to put my
notification code and guarantee that it will be rendered to the user? Worst
case I could add a timer behavior to the panel that makes a callback to the
server and executes the notification, but I don't really like that solution.

Josh



--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/IExceptionMapper-to-notify-support-of-errors-tp4651251p4651254.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: IExceptionMapper to notify support of errors

Posted by Igor Vaynberg <ig...@gmail.com>.
perhaps an error occurs during an ajax request whose response is
ignored. or maybe it happens during resource processing...

eg tinymce requests a resource, wicket doesnt find it and throws an
exception. your panel renders. but, because the url was for a resource
the response is ignored because its not a 200 response.

-igor


On Wed, Aug 15, 2012 at 9:40 AM, jchappelle <jc...@4redi.com> wrote:
> I have written an IExceptionMapper that notifies our support team if an
> unexpected exception occurs. It will redirect the user to our ErrorPage and
> in the ErrorPanel.onBeforeRender I send a notification via email in a new
> Thread. This mostly works except we are getting several false positives.
> What I mean is that the user never sees the ErrorPanel and continues to
> work. So our support team doesn't know if the user really notices an error
> or not.
>
> Here are the things that I don't understand about this behavior. If my
> notification code is in the onBeforeRender of my ErrorPanel, then how does
> this code execute and the user never see the panel? Also, we keep getting
> the following exceptions (it seems to happen where we have a tinymce in a
> form). The first one we see in development only but the second we see in
> production only. However, they both seem to be around
> org.apache.wicket.request.mapper.AbstractComponentMapper.getPageClass. The
> second generates a notification and the user never sees the ErrorPanel.
>
> *Error seen in development environment:*
>
> *Error seen in production*
>
>
>
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/IExceptionMapper-to-notify-support-of-errors-tp4651251.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
>

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