-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement task progress HTTP polling (#543)
If the web socket is closed, task progress messages are lost. If the "completed" or "aborted" message is among lost messages a progress notifications remains freezed. Add a setTimeout/clearTimeout invocation for each WS message received. After 8 seconds, if no further message comes, send an HTTP GET request with getTaskStatus() to verify the task status from API server. If the HTTP request fails, try again after 8 seconds. If it succeeds generate a synthesized progress message that completes the task progress at 100%.
- Loading branch information
1 parent
6497256
commit fe17db5
Showing
2 changed files
with
61 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters