Hi all,

I upgraded my application from M8 to M9 yesterday and encountered 3 issues:

1. Current WiQuery version is not compatible with M9

It still depends on WicketEventJQueryResourceReference. It would be great
if someone could cut a milestone release for WiQuery as well, so I can do
further testing with my application.

2. Failing tests for components with AjaxLazyLoadPanel

It seems that it is not possible anymore, to load an AjaxLazyLoadPanel
during an Ajax request. I have a panel that is initially invisible and
shown via an Ajax toggle link that contains a AjaxLazyLoadPanel. My test
fails with:

java.lang.IllegalStateException: Components can no  longer be added
> at
> org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:854)
> at
> org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:847)
> at org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:444)
> at
> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:263)
> at
> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239)
> at
> org.apache.wicket.extensions.ajax.markup.html.AjaxLazyLoadPanel.lambda$isLoaded$1(AjaxLazyLoadPanel.java:258)
> at java.util.Optional.ifPresent(Optional.java:159)
> at
> org.apache.wicket.extensions.ajax.markup.html.AjaxLazyLoadPanel.isLoaded(AjaxLazyLoadPanel.java:258)
> at
> org.apache.wicket.extensions.ajax.markup.html.AjaxLazyLoadPanel.onConfigure(AjaxLazyLoadPanel.java:212)

The toggle link sets the panel containing the lazy-load panel visible and
adds it to the ajax target:

public void onClick(AjaxRequestTarget target) {
> component.setVisible(!component.isVisible());
> target.add(component);
> }

3. Removed (internal) APIs

I have a custom component for rendering an infinite-scrolling list that
uses two (internal) methods to update the underlying DataView:

public void onClick(AjaxRequestTarget target) {
>     pageable.setItemsPerPage(pageable.getItemsPerPage() +
> additionalItems);

>     view.afterRender();


Both `prepareForRender` and `afterRender` are no longer accessible. Does
anyone have a suggestion what I could call instead? I sadly do not remember
why exactly we work against Wicket's default rendering in that case but it
looks like we want to do everything *except* the actual render.

Best regards,


Reply via email to