tern.java
tern.java copied to clipboard
Implement tern server with Nashorn
try and write results here
Please not that some tern plugins like closure, node.js depends on node.js for some features. Ex tern plugin node uses node to resolver module name declared inside require because it needs file system API)
@mickaelistria @vrubezhny @dgolovin @maxandersen @PaulVI @fbricon @piotrtomiak I have implemented quickly tern server with Nashorn (but not the integration with Eclipse IDE).
You can find info at (samples to launch, etc) https://github.com/angelozerr/tern.java/blob/master/core/tern.server.nashorn/README.md
But I'm very disappointed, because I find the load of tern server is very slowly with Nashorn compared to Node.js or J2V8. Completion with big files with Nashorn is very slow -(
Perhaps my integration is not very performant?
At least, this is real world example for now.
BTW, https://github.com/angelozerr/tern.java/blob/master/README.md needs to be updated, it is not only idea now...
Showing that there's choice.
BTW, https://github.com/angelozerr/tern.java/blob/master/README.md needs to be updated, it is not only idea now...
done
Perhaps my integration is not very performant?
No, it's not your fault ;) In the early days of adopting Tern in MyEclipse we've checked performance comparisons of Nashorn, Rhino and V8 (both Node.js and J2V8 are based on V8) and it looked like Nashorn is only slightly better than Rhino, and Rhino is pretty slow with Tern.
Thanks @piotrtomiak for your feedback. Yes today node > J2V8 > Nashorn > Rhino.
When you will have tipe, could you answer me for https://github.com/angelozerr/tern.java/issues/363 with WebSocket topic. I have started to implement WebSocket on server/client side with Jetty (for the moment tern server send a message to the Java client and I display the result in the console). Any feedback are welcome. thanks!