Thanks for that, Martin. I've updated https://issues.apache.org/jira/browse/ISIS-1176 with this info.
On 30 October 2016 at 12:39, Martin Grigorov <[email protected]> wrote: > Hi, > > > On Sat, Oct 29, 2016 at 7:43 PM, Dan Haywood <[email protected] > > > wrote: > > > inline > > > > On 29 October 2016 at 13:05, Bilgin Ibryam <[email protected]> wrote: > > > > > > > > > > > Are there any examples of simple wicket widget that refresh from the > > > backend? What would be the closes code sampel to that? > > > > > > > > [4] http://examples7x.wicket.apache.org/atmosphere/?0 > > > > the source code link is to the right hand side. > > > > @martin-g - do you know of any other resources/approaches? > > > > The simplest way is to use > AbstractTimerAjaxBehavior/AjaxSelfUpdatingBehavior. This would do polling, > i.e. every N seconds an Ajax call will be made to check whether there is > new data to show. > > If you need to do server push, i.e. whenever new data comes to push it > immediately to the client then I'd suggest Wicket Native WebSocket instead > of Atmosphere. Nowadays all browsers support WebSocket (IE10+ and all > others) and almost everyone deploys on web server that support JSR 356 - > https://ci.apache.org/projects/wicket/guide/7.x/ > guide/nativewebsockets.html. > It's usage is as easy as Wicket Ajax. > > Another option is Server Send Events ( > https://github.com/wicketstuff/core/tree/master/ > wicket-html5-parent/wicket-html5, > demo: > https://github.com/wicketstuff/core/tree/master/ > wicket-html5-parent/wicket-html5-examples/src/main/java/ > org/wicketstuff/html5/eventsource > ) > > > > > > > > > > > > > >
