Hi,

2012/2/29 Andre Schütz <andre-p...@gmx.de>:
> Hello,
>
> I have a problem with my application that I am not able to solve since
>  the last three days.
>
> I realized that Wicket 1.5 provides multi tab / multi window support
> for more than one opened tab in a browser.
> I have a problem with multiple tabs in my program, that I want to
> describe now.
>
> The program consists of two pages. Page1 contains a search field that
> will be used to type in a search word.
> Page2 makes the search on a database, returns the results and
> displays it as a list. The search will be done from a background
> thread that stores the result in a hashmap in the session with the
> search word as the key. Furthermore, Page2 shows a little loading
> animation that will be updated (AjaxSelfUpdatingTimerBehavior), when the
> result is stored in the session.
>
> Now the problem.
>
> (1) I open the application in two tabs of the same browser.
> (2) The URL looks as follows:
> Tab1 - localhost:8080/appli/?0
> Tab2 - localhost:8080/appli/?1
> (3) Tab1 gets word1 in the search field and Tab2 gets word2
> into the search field.
> (4) I press the submit button of Tab1, switch to Tab2 and press the
> submit button, too.
> (5) The two Threads start to search for the results.
> (6) During the AjaxSelfUpdatingTimeBehavior, the result panel of Page2 checks
> in its overwritten onBeforeRender method for the results. When the result
> for the search word is found in the session, the updateBehavior of Page2
> is stopped and the results will be displayed.
> -> Here starts my problem:
>
> None of the two pages will be updated and show the results. If I start
> the search in one of the Tabs, the process will be finished and the
> results displayed onto the screen.
>
> For me, it seems that both tabs share the same session data and also
> the same updateBehavior on the Page2.

Same session - yes.
Same behavior instance - no. You can verify that with a breakpoint in
#onTimer() method and checking 'this'.

>
> Can anybody help me with that problem? Would be great.
>
> --
> Andre Schütz <schuetz.an...@gmx.net>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to