Loading indicator appearing because of refresher

Hi,

I’m using the Refresher for a very simple reason: I want all the UIs to be communicated when a session is closed from any of them. That is working fine but my problem is that the Refreseher is making the loading indicator to flash and I don’t know if there’s any way to solve it. It’s very annoying to see the spinning wheel every 3 seconds and it can be confusing for users.

Thanks!

Hi,

the communications that the Refresher initiates use the exact same communication mechanism as any other request from the vaadin client side. Unfortunately this means that you can’t selectively hide the loading indicator for refresher-initiated requests and show it for others.

Do you have a lots of data updated on each request, or high latency and/or high load on the server? The first (white) loading indicator is shown after the request has taken over 300ms to complete, which should be enough time for a simple request with a small amount of data to get a response.

One option would of course be to change to using the push mechanism, then you would only get traffic when it’s actually needed.

As a workaround, in Vaadin 7.1, you can increase the loading indicator delays using UI.getLoadingIndicatorConfiguration(). This of course applies to all traffic, not just the refresh requests, but setting it to a second or so would probably be an acceptable compromise.