Table changeVariables called to often


I have created a own table who extends from the vaadin standard table. So i can get a event, if the scrollbars will moved. I called it ScrollableTable.
Thats works fine!
But now i have a problem. If i use my table a few minutes, the handling slow down. The loading of the items while scrolling down needs longer time and the left scroll event, too. I wondered and i found the reason. The changeVariables()-Methode will called at the first time only 2 times and the calls will increase… But i don´t know why?

Is this a bug ?

I hope i can display it for you.


My problem still alive… Have nobody a workaround or something like this?


It can be a bug in vaadin, but it can be a bug in how you extended the table.
Without seeing some code it is hard to answer.

Hard to say without knowing more. changeVariables() is called whenever the UI sends a message to the server about something happening, so you should get one (or a few at most, depending on what is set up to be sent immediately etc.) call per scroll position that is sent.

You should probably make sure you are not sending tens or hundreds of scroll events while moving the mouse. You can use e.g. a timer for some tens or hundreds of milliseconds that combines such updates before queuing them to be sent.

Thanks for your answers.

I used the code snippet out of this post:

I think a timer don´t solve my problem. Because at the begin i became two events. A few actions later i became on the same action four or five events and so the table slow down. After 10-15 minutes the table is unusable.


The problem in that code seems to be that new scroll listeners are registered on every update from the server. This should only be done once.

Hm i think it wouldn´t happen.
Can u give me the line in which this problem should happen?

Henri has already replied in the other thread,
highlighting in bold where the handler is being added on every update.