Community
Participate
Working Groups
Currently when we make a request of Tern we send the file array with it. It would be better if we only removed / updated files in Tern based on what the workspace says. This would save inferencing time for dependencies that have not changed and other places.
Moving out of 9.0 and lowering priority, I found that having the worker handle changed* events causes some very bad behaviour when the Tern server is in the middle of an operation and an even causes a file Tern is using to be removed or updated. The proper fix will require a proxy of sorts to be able to tell Tern to cancel what it is doing if an in-use file has been changed (currently the version of the server we use does not have support for this).
We can also use the new js project context as a way to know when files have been deleted / renamed / moved / created - allowing us to update Tern accordingly.
Created attachment 262085 [details] POC This patch adds a client-side edited state cache. If the file has not been changed, sanitize the request to not forward the source as part of the files array - which avoid an entire parse + infer pass in the worker for that (and subsequent) requests.
Fixed in: http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=78a562b2145b709f5dd037d910ceb3dc351d4f47 All tests pass.
*** Bug 474420 has been marked as a duplicate of this bug. ***