private JSObject window;

        public void documentUpdated( String newDocumentId ) {

                window.call( "documentUpdated", new String[] { param1, param2 } 
);              
        }

> -----Original Message-----
> From: Martin Grigorov [mailto:mgrigo...@apache.org]
> Sent: Monday, November 26, 2012 16:51
> To: users@wicket.apache.org
> Subject: Re: multiple requests and StalePageException
> 
> Can you show the code that the applet uses to make requests to the page
> ?
> 
> 
> On Mon, Nov 26, 2012 at 4:47 PM, Michal Wegrzyn
> <michal.wegr...@onior.com>wrote:
> 
> > Hi Martin,
> >
> > Thanks for a tip. What do you mean by "uses Wicket.Ajax.**"?
> >
> > Applet till now generated fake event to trigger Wicket ajax behavior.
> >
> > I have just tried calling behavior directly with wicketAjaxGet (
> > https://cwiki.apache.org/WICKET/calling-wicket-from-javascript.html)
> > but I get the same result.
> >
> > Best regards,
> > Michal Wegrzyn
> >
> > > -----Original Message-----
> > > From: Martin Grigorov [mailto:mgrigo...@apache.org]
> > > Sent: Monday, November 26, 2012 14:03
> > > To: users@wicket.apache.org
> > > Subject: Re: multiple requests and StalePageException
> > >
> > > The renderCount increases only when you use non-Ajax requests, i.e.
> > > when you re-render the whole page.
> > > Make sure that "executes Wicket behavior via js" uses
> Wicket.Ajax.**
> > >
> > >
> > > On Mon, Nov 26, 2012 at 1:56 PM, Michal Wegrzyn
> > > <michal.wegr...@onior.com>wrote:
> > >
> > > > Hi group,
> > > >
> > > > In my Wicket application I have an applet. In the background it
> > > > requests servlet and finally executes Wicket behavior via js.
> > > > If one request is performed, then everything works without
> problems.
> > > >
> > > > Lately I have changed applet and now it can do one or three
> requests.
> > > > If it performs three requests then StalePageException is thrown,
> > > which
> > > > causes page refreshed and that is not a desired behavior.
> > > > When I debug difference between render counter and page counter
> is
> > > > exactly 2, so I think that issue is connected with two "extra"
> > > > applet
> > > requests.
> > > >
> > > > Do I miss something on the Wicket side? If not, what is the best
> > > > way to avoid StalePageException in this case?
> > > >
> > > > Best regards,
> > > > Michal Wegrzyn
> > > >
> > >
> > >
> > >
> > > --
> > > Martin Grigorov
> > > jWeekend
> > > Training, Consulting, Development
> > > http://jWeekend.com <http://jweekend.com/>
> >
> 
> 
> 
> --
> Martin Grigorov
> jWeekend
> Training, Consulting, Development
> http://jWeekend.com <http://jweekend.com/>

Reply via email to