Disabling/Enabling a button

Hello all, I am new to vaadin.

I have button which I disable in my buttonclick method of the Button.ClickListener. I am using the PUSH capability to later enable this button.

My problem is that it is taken 1.5 minutes for the button to be enabled on the browser.

I have set the setImmediate(true) for this button.

Any ideas why it is taking so long?

setImmediate only controls client to server communication, not the other way around.

Are you sure your push channel is set up correctly? What server/browser are you using? What push transport?

I understand how the setImmediate works and I am trying to have the server communcate with the client to enable the button.

I am updating two labels and they are working.

I am using firefox, version 24

I am using Vaadin 7 and it’s push capability.

What server are you using? are you using websockets or streaming?

If Label updating works then Button updating should work as well. Just to be clear; you mean that after you run button.setEnabled(true), it takes about 90 seconds for the button to become enabled? Is it always 90 seconds? Can you check if the change is because a client-to-server call (polling, heartbeat, etc.)?

Can you provide a simple test case to demonstrate this?

Sorry for all the questions, but I can’t really help you without the information… :slight_smile:

One more question: do you have any proxies, reverse proxies etc. between the server and the browser? Or does this occur for you even with the server and the browser on the same computer?

You can check whether websockets or streaming is actually used on the info page of the debug window (add “?debug” to the URL).