After upgrading from Wicket 7 to Wicket 8, page mounting does not work anymore.
In Wicket 7 I added
new AnnotatedMountScanner().scanPackage("com.example").mount(this);
in my init()
method of my AuthenticatedWebApplication
And on my page I added @MountPath("/mypage")
.
In Wicket 8 this does not work anymore and instead of /mypage
the browser URL points to wicket/bookmarkable/com.example.MyPage
, however when I manually add
mountPage("AAA", MyPage.class);
it works.
Here is my classpath with all wicket dependencies:
$ mvn dependency:tree | grep wicket [INFO] +-
org.apache.wicket:wicket-core:jar:8.0.0:compile [INFO] | +-
org.apache.wicket:wicket-request:jar:8.0.0:compile [INFO] | +-
org.apache.wicket:wicket-util:jar:8.0.0:compile [INFO] +-
org.wicketstuff:wicketstuff-annotation:jar:8.0.0:compile [INFO] +-
org.apache.wicket:wicket-spring:jar:8.0.0:compile [INFO] | -
org.apache.wicket:wicket-ioc:jar:8.0.0:compile [INFO] +-
org.apache.wicket:wicket-datetime:jar:8.0.0-M7:compile [INFO] +-
org.apache.wicket:wicket-auth-roles:jar:8.0.0:compile [INFO] +-
de.agilecoders.wicket:wicket-bootstrap-core:jar:2.0.2:compile [INFO]
| +- de.agilecoders.wicket:jquery-selectors:jar:2.0.0:compile [INFO] | +- de.agilecoders.wicket.webjars:wicket-webjars:jar:2.0.7:compile [INFO] | +- org.apache.wicket:wicket-extensions:jar:8.0.0:compile [INFO] +- de.agilecoders.wicket:wicket-bootstrap-extensions:jar:2.0.2:compile
[INFO] +-
com.googlecode.wicket-jquery-ui:wicket-jquery-ui-plugins:jar:8.0.0-M7:compile [INFO] | -
com.googlecode.wicket-jquery-ui:wicket-jquery-ui-core:jar:8.0.0-M7:compile
But I do not want to add all mypages manually. Is it possible to also use the AnnotatedMountScanner
again in Wicket 8?