aboutsummaryrefslogtreecommitdiffstats
path: root/client/src
diff options
context:
space:
mode:
authorTatu Lund <tatu@vaadin.com>2021-01-07 13:21:46 +0200
committerGitHub <noreply@github.com>2021-01-07 13:21:46 +0200
commit21ff79aea40e2a3d998449efbae780dca3eb987e (patch)
treeba327b73054fde32ef92c0b1575f5ab67a803272 /client/src
parenta250bde2bf0ae47368e3c8d0f339567254b40262 (diff)
downloadvaadin-framework-21ff79aea40e2a3d998449efbae780dca3eb987e.tar.gz
vaadin-framework-21ff79aea40e2a3d998449efbae780dca3eb987e.zip
Move call to getMessageHandler().onResynchronize(); to right place (#12178)
https://github.com/vaadin/framework/pull/12043 changed resync message sending to be deferred to queue. Now also the setting of the semaphor in message handler needs to be deferred to its right place. Otherwise there is possibility for a timing glitch. I.e. MessageHandler is set to resync handling mode before message is actually send. Fixes: https://github.com/vaadin/framework/issues/12151
Diffstat (limited to 'client/src')
-rw-r--r--client/src/main/java/com/vaadin/client/communication/MessageSender.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/client/src/main/java/com/vaadin/client/communication/MessageSender.java b/client/src/main/java/com/vaadin/client/communication/MessageSender.java
index 9a443adb2e..969e38ef5d 100644
--- a/client/src/main/java/com/vaadin/client/communication/MessageSender.java
+++ b/client/src/main/java/com/vaadin/client/communication/MessageSender.java
@@ -127,6 +127,7 @@ public class MessageSender {
}
if (resynchronizeRequested) {
getLogger().info("Resynchronizing from server");
+ getMessageHandler().onResynchronize();
extraJson.put(ApplicationConstants.RESYNCHRONIZE_ID, true);
resynchronizeRequested = false;
}
@@ -356,7 +357,6 @@ public class MessageSender {
* state from the server
*/
public void resynchronize() {
- getMessageHandler().onResynchronize();
getLogger().info("Resynchronize from server requested");
resynchronizeRequested = true;
sendInvocationsToServer();