Maybe use an IRequestCycleListener and maybe use onRequestHandlerExecuted.
See

private void execute(IRequestHandler handler)
{
Args.notNull(handler, "handler");

try
{
listeners.onRequestHandlerResolved(this, handler);
requestHandlerExecutor.execute(handler);
listeners.onRequestHandlerExecuted(this, handler);
}
catch (RuntimeException e)
{
IRequestHandler replacement = requestHandlerExecutor.resolveHandler(e);
if (replacement != null)
{
execute(replacement);
}
else
{
throw e;
}
}
}

Ajax request handler has a

@Override
public final Collection<? extends Component> getComponents()
{
return responseObject.getComponents();
}



On Sun, Jan 5, 2014 at 10:51 AM, Ernesto Reinaldo Barreiro <
[email protected]> wrote:

> Maybe use an IRequestCycleListener and maybe use
>
>
>
>
> On Sun, Jan 5, 2014 at 4:15 AM, jchappelle <[email protected]> wrote:
>
>> We get a lot of ComponentNotFoundExceptions in production and I have not
>> been
>> able to reproduce them. I've had discussions on here before about this
>> and I
>> think what is happening is that the user clicks something to change the
>> state of the page, say it removes a button. If we don't add the panel to
>> the
>> AjaxRequestTarget then the button will still be there on the browser for
>> the
>> user to click. When they click that button wicket throws this exception
>> because the server side does not find that button in the component
>> hierarchy(or it isn't visible or whatever).
>>
>> So my question is how can I detect when an Ajax request happens and
>> nothing
>> gets added to the AjaxRequestTarget and log it out? Or is there a better
>> way
>> to run this down? I'm open to any ideas or strategies for fixing this
>> issue.
>>
>> Thanks,
>>
>> Josh
>>
>> --
>> View this message in context:
>> http://apache-wicket.1842946.n4.nabble.com/Detecting-when-nothing-is-added-to-AjaxRequestTarget-tp4663469.html
>> Sent from the Users forum mailing list archive at Nabble.com.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>>
>>
>
>
> --
> Regards - Ernesto Reinaldo Barreiro
>



-- 
Regards - Ernesto Reinaldo Barreiro

Reply via email to