Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Spike] Pre-requisite for fault-tolerant client-server #20418

Open
3 tasks
mshabarov opened this issue Nov 6, 2024 · 2 comments
Open
3 tasks

[Spike] Pre-requisite for fault-tolerant client-server #20418

mshabarov opened this issue Nov 6, 2024 · 2 comments
Assignees

Comments

@mshabarov
Copy link
Contributor

Describe your motivation

This is a pre-requisite investigation task before we can start #20348.
The description there is not enough to start the development and it costs too many story points from the team's opinion, thus needs a decomposition.

The outcome of this investigation should be:

  • Describing and understanding what are the cases might be, when message ID is unexpected. This should give enough technical details to deduct what and where exactly we have to change in framework . This ticket can be considered as a source of real observations Unexpected message id from the client (sync ids different) #12640, but not only limited to those.
  • A list of enhancements with <= 8 story points that could address the cases, where the network is a culprit, i.e. when the messages are lost. The cases, caused by misconfiguration of session replication, should be described, but out of scope of further enhancements in framework. Though they should be properly documented.
  • A testing procedure needs to be ready, at least the idea how we can test these enhancements and guarantee that they cover real cases.
@caalador
Copy link
Contributor

Cases seen in reported logs:

  • Ignore old message from client
    • Server receives previous message id with the same content hash as last processed
    • Server should resend last response to sync state on client.
  • Unexpected id from client
    • If the client id is bigger than the expected there has been a dropped client request. (client updates the id on preparePayload)
    • Client should be requested to resend previous message and server should sync the id to current request id.
  • Server expected much bigger than the client request?
    • Resynchronization should probably happen as the gap is too big and why is the client requesting with much too old id?

@caalador
Copy link
Contributor

As the server always answers the client, the client should probably queue the sends as it does for one single pushPendingMessage when using bidirectional transport, but not for xhr. Also send(JsonObject payload) is public and doesn't do any queueing so that sendInvocationsToServer would purge them instead of pushing it out immediately where we could possibly get faulty sync id from the client.

@mshabarov mshabarov self-assigned this Nov 13, 2024
@mshabarov mshabarov moved this from 🟢Ready to Go to ⚒️ In progress in Vaadin Flow ongoing work (Vaadin 10+) Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ⚒️ In progress
Development

No branches or pull requests

2 participants