You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Robin Shine (JIRA)" <ji...@apache.org> on 2014/03/28 10:20:14 UTC
[jira] [Created] (WICKET-5546) Adding behavior in component
instantiation listener causes Page.onInitialize() being called even if
constructor throws an exception
Robin Shine created WICKET-5546:
-----------------------------------
Summary: Adding behavior in component instantiation listener causes Page.onInitialize() being called even if constructor throws an exception
Key: WICKET-5546
URL: https://issues.apache.org/jira/browse/WICKET-5546
Project: Wicket
Issue Type: Bug
Components: wicket
Affects Versions: 6.14.0, 6.13.0
Reporter: Robin Shine
Priority: Minor
Page.onInitialize() will be called even if constructor throws an exception
in case below code is added in wicket WebApplication.init():
getComponentInstantiationListeners().add(new IComponentInstantiationListener() {
@Override
public void onInstantiation(Component component) {
component.add(new Behavior() {
});
}
});
It seems that the instantiation listener adds the behavior to the page at very start of the page constructor, and then the page is marked as dirty to cause onInitialize() being called afterwards.
--
This message was sent by Atlassian JIRA
(v6.2#6252)