Re: WicketRuntimeException: loginPage is already mounted for BookmarkablePageEncoder[page=class com.xxx.LoginPage]
Igor, I did what you pointed me out. However, I got a MarkupNoFoundExpcetion. My code try{ application=(WebApplication) MiSession.get().getApplication(); }catch(Exception e){ application=new BaseWicketTester.DummyWebApplication(){ protected void init(){ getApplicationSettings().setDefaultMaximumUploadSize(Bytes.bytes(500)); getResourceSettings().addResourceFolder("/WEB-INF/html"); } }; application.mountBookmarkablePage("mensaje", PaginaMensajeEvento.class); } It says that PaginaMensajeEvento doesn't have a markup which is not true. Actually, when I don't use this code into a separate servlet, It runs smoothly. thanks in advance On Thu, Sep 2, 2010 at 6:49 PM, Igor Vaynberg wrote: > you can create a new instance > > -igor > > On Thu, Sep 2, 2010 at 1:49 PM, Fernando Wermus > wrote: > > Igor, > >When I don't pass the application I got the following error > > > > RuntimeException: There is no application attached to current thread > > btpool0-3 - /messagebroker/amf > > > > This is because I need to render the emails from a different servlet. Do > I > > have any solution for this situation? > > > > How can I get the WebApplication from a different servlet? > > > > On Thu, Sep 2, 2010 at 1:26 PM, Igor Vaynberg >wrote: > > > >> you should pass a new instance of application. wicket tester inits the > >> application and so it would call the init method which will execute > >> the mounts - and on already initialized instance it would cause that > >> error. > >> > >> -igor > >> > >> On Thu, Sep 2, 2010 at 9:13 AM, Fernando Wermus > >> wrote: > >> > Hi all, > >> > I am using wicketTester to render html for emails. I pass my > current > >> app > >> > to WicketTester and I get the following error: > >> > > >> > WicketRuntimeException: loginPage is already mounted for > >> > BookmarkablePageEncoder[page=class com.xxx.LoginPage] > >> > > >> > Which makes no sense. The Application is running and I just passing it > to > >> > the WicketTester constructor. > >> > > >> > any help would be really appreciated. > >> > > >> > thanks in advance > >> > > >> > -- > >> > Fernando Wermus. > >> > > >> > www.linkedin.com/in/fernandowermus > >> > > >> > >> - > >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > >> For additional commands, e-mail: users-h...@wicket.apache.org > >> > >> > > > > > > -- > > Fernando Wermus. > > > > www.linkedin.com/in/fernandowermus > > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fernando Wermus. www.linkedin.com/in/fernandowermus
Re: WicketRuntimeException: loginPage is already mounted for BookmarkablePageEncoder[page=class com.xxx.LoginPage]
you can create a new instance -igor On Thu, Sep 2, 2010 at 1:49 PM, Fernando Wermus wrote: > Igor, > When I don't pass the application I got the following error > > RuntimeException: There is no application attached to current thread > btpool0-3 - /messagebroker/amf > > This is because I need to render the emails from a different servlet. Do I > have any solution for this situation? > > How can I get the WebApplication from a different servlet? > > On Thu, Sep 2, 2010 at 1:26 PM, Igor Vaynberg wrote: > >> you should pass a new instance of application. wicket tester inits the >> application and so it would call the init method which will execute >> the mounts - and on already initialized instance it would cause that >> error. >> >> -igor >> >> On Thu, Sep 2, 2010 at 9:13 AM, Fernando Wermus >> wrote: >> > Hi all, >> > I am using wicketTester to render html for emails. I pass my current >> app >> > to WicketTester and I get the following error: >> > >> > WicketRuntimeException: loginPage is already mounted for >> > BookmarkablePageEncoder[page=class com.xxx.LoginPage] >> > >> > Which makes no sense. The Application is running and I just passing it to >> > the WicketTester constructor. >> > >> > any help would be really appreciated. >> > >> > thanks in advance >> > >> > -- >> > Fernando Wermus. >> > >> > www.linkedin.com/in/fernandowermus >> > >> >> - >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >> For additional commands, e-mail: users-h...@wicket.apache.org >> >> > > > -- > Fernando Wermus. > > www.linkedin.com/in/fernandowermus > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: WicketRuntimeException: loginPage is already mounted for BookmarkablePageEncoder[page=class com.xxx.LoginPage]
Igor, When I don't pass the application I got the following error RuntimeException: There is no application attached to current thread btpool0-3 - /messagebroker/amf This is because I need to render the emails from a different servlet. Do I have any solution for this situation? How can I get the WebApplication from a different servlet? On Thu, Sep 2, 2010 at 1:26 PM, Igor Vaynberg wrote: > you should pass a new instance of application. wicket tester inits the > application and so it would call the init method which will execute > the mounts - and on already initialized instance it would cause that > error. > > -igor > > On Thu, Sep 2, 2010 at 9:13 AM, Fernando Wermus > wrote: > > Hi all, > >I am using wicketTester to render html for emails. I pass my current > app > > to WicketTester and I get the following error: > > > > WicketRuntimeException: loginPage is already mounted for > > BookmarkablePageEncoder[page=class com.xxx.LoginPage] > > > > Which makes no sense. The Application is running and I just passing it to > > the WicketTester constructor. > > > > any help would be really appreciated. > > > > thanks in advance > > > > -- > > Fernando Wermus. > > > > www.linkedin.com/in/fernandowermus > > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fernando Wermus. www.linkedin.com/in/fernandowermus
Re: WicketRuntimeException: loginPage is already mounted for BookmarkablePageEncoder[page=class com.xxx.LoginPage]
you should pass a new instance of application. wicket tester inits the application and so it would call the init method which will execute the mounts - and on already initialized instance it would cause that error. -igor On Thu, Sep 2, 2010 at 9:13 AM, Fernando Wermus wrote: > Hi all, > I am using wicketTester to render html for emails. I pass my current app > to WicketTester and I get the following error: > > WicketRuntimeException: loginPage is already mounted for > BookmarkablePageEncoder[page=class com.xxx.LoginPage] > > Which makes no sense. The Application is running and I just passing it to > the WicketTester constructor. > > any help would be really appreciated. > > thanks in advance > > -- > Fernando Wermus. > > www.linkedin.com/in/fernandowermus > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
WicketRuntimeException: loginPage is already mounted for BookmarkablePageEncoder[page=class com.xxx.LoginPage]
Hi all, I am using wicketTester to render html for emails. I pass my current app to WicketTester and I get the following error: WicketRuntimeException: loginPage is already mounted for BookmarkablePageEncoder[page=class com.xxx.LoginPage] Which makes no sense. The Application is running and I just passing it to the WicketTester constructor. any help would be really appreciated. thanks in advance -- Fernando Wermus. www.linkedin.com/in/fernandowermus