Window not responding when server is under heavy load #7652
Unanswered
ALjungfjar
asked this question in
Q&A
Replies: 1 comment
-
|
If the main thread is getting held up by a heavy task (such as your XML parsing), it'll cause holdup on everything else on the main thread (WebView included), so your idea of moving the request and processing to a separate thread is probably the best option. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I have a Tauri application which is using http REST api for communication between server and client.

I am using an xml library called xmltree.
Whenever I send a request telling the server to open the passed xml file path and parse it to an element in memory the window stops responding, as following:
After the xml element has been parsed the window starts to respond again, so it is obviously the parsing which creates this behavior.
The request I am doing is asynchronous so client should still be responsive while the server processes the data. To me this looks like the container of the webview stops responding because of the server runtime chewing on some heavy stuff. Is this possible? What should I do to fix this problem? Make the xml parsing use its own thread?
The request I am making from the client is very simple, looks as following:
fetch(host/document/${filePath}/open, { method: "POST", mode: "no-cors", })Beta Was this translation helpful? Give feedback.
All reactions