Wicket
  1. Wicket
  2. WICKET-2887

Bootstraping wicket with GuiceWebApplicationFactory fails with exception

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 1.4.8, 1.4.9
    • Fix Version/s: None
    • Component/s: wicket-guice
    • Labels:
      None

      Description

      There seems to be some sort of chicken-egg problem:
      org.apache.wicket.WicketRuntimeException: There is no application attached to current thread main
      at org.apache.wicket.Application.get(Application.java:179) [wicket-1.4.9.jar:1.4.9]
      at org.apache.wicket.injection.web.InjectorHolder.setInjector(InjectorHolder.java:88) [wicket-ioc-1.4.9.jar:1.4.9]
      at org.apache.wicket.guice.GuiceComponentInjector.<init>(GuiceComponentInjector.java:102) [wicket-guice-1.4.9.jar:1.4.9]
      at org.apache.wicket.guice.GuiceWebApplicationFactory.createApplication(GuiceWebApplicationFactory.java:177) [wicket-guice-1.4.9.jar:1.4.9]
      at org.apache.wicket.protocol.http.WicketFilter.init(WicketFilter.java:701) [wicket-1.4.9.jar:1.4.9]

      After some digging i found that it is actually a regression made by this issue fix - WICKET-2761.
      If I rollback wicket-guice to 1.4.7, everything starts to work just fine.

      1. WICKET-2887-1.4.9.patch
        3 kB
        Zilvinas Kybartas

        Activity

          People

          • Assignee:
            Igor Vaynberg
            Reporter:
            Zilvinas Kybartas
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development