PDA

View Full Version : Performance



iver25
1 Dec 2015, 4:14 AM
Am I the only one that experiences major performance issues with the editor?

When I hit Ctrl+c to copy code, it takes around 10 seconds before I can use the editor again.

When I make an error, for example missing a comma, it also takes it around 10 seconds to find it.

As you can see here, the javascript parser is outdated. Is that something you are aware of?
: http://www.gorkem-ercan.com/2015/11/benchmarking-javascript-parsers-for.html

Chris.OBrien
1 Dec 2015, 7:36 AM
Am I the only one that experiences major performance issues with the editor?

When I hit Ctrl+c to copy code, it takes around 10 seconds before I can use the editor again.

When I make an error, for example missing a comma, it also takes it around 10 seconds to find it.

As you can see here, the javascript parser is outdated. Is that something you are aware of?
: http://www.gorkem-ercan.com/2015/11/benchmarking-javascript-parsers-for.html


What version of Visual Studio are you using? Or are you using Eclipse, since the article you posted mentions Eclipse JSDT.

Our background process that parses our JavaScript for the Sencha plugins (for both Visual Studio and Eclipse) does use Acorn, the first parser mentioned in the article above. I would imagine any slowdown you are experiencing might be from the IDE itself trying to parse JavaScript.

Do you have a large project?

iver25
1 Dec 2015, 10:23 PM
Sorry, I thought I was on the Eclipse Plugin Forum...We use Eclipse version Mars, and yes we have a fairly large project (more than 25000 lines). If it helps at all, I can inform you that we don't use Sencha Cmd in the project, so maybe the plugin is missing som information about the project.

Chris.OBrien
1 Dec 2015, 10:36 PM
I've moved this thread to the Eclipse Forums, thanks.

Regarding your issues, I think you might be running into the same issues documented on these StackOverflow links:

https://stackoverflow.com/questions/3515422/why-does-eclipse-hang-on-copy-paste-in-javascript-files

For me the solution was disable this option...
Preferences/JavaScript/Editor/Typing{When pasting}/Update imports

https://stackoverflow.com/questions/20392791/eclipse-hangs-on-copy-cut-for-javascript-files (https://stackoverflow.com/questions/20392791/eclipse-hangs-on-copy-cut-for-javascript-files)

go to Window>Preferences>JavaScript>Editor>Mark Occurrences and unselect the checkboxes. That should do it.

It looks like Eclipse's JSDT has problems with large projects, so I'd try the suggestions from the links above. Our plugin uses a different process in the background which is not reliant on the JSDT for parsing.

You could also potentially exclude the bulk of your JavaScript in your project from JSDT's parsing using these steps here, and instead of excluding the SDK, you could potentially exclude all of your JavaScript source.


We also have our GA release right around the corner, so keep an eye out for that, since it includes bug fixes and other performance improvements for our plugin (but would not change this JSDT parse problem since that is Eclipse)

iver25
1 Dec 2015, 10:44 PM
Thank you for some great links. I will try some of the solutions out.When you say I should try to exclude the SDK, or my own code, doesn't that mean that I won't get any of the features for this code? That would not be desireable. I hope I can disable things I don't need, and that that will be enough.

iver25
1 Dec 2015, 10:47 PM
On a quick side note. The plugin documentation doesn't describe if the user has to do anything special when the project is not using Sencha Cmd.Does the plugin work equally well on projects that use Sencha Cmd, and projects that don't?Do we need to do anything to our project, now that we don't use Sencha Cmd?Thanks

Chris.OBrien
1 Dec 2015, 11:03 PM
Thank you for some great links. I will try some of the solutions out.When you say I should try to exclude the SDK, or my own code, doesn't that mean that I won't get any of the features for this code? That would not be desireable. I hope I can disable things I don't need, and that that will be enough.

If the StackOverflow links don't work above, definitely try just excluding the SDK first. I would only exclude your source as a last-resort.

That being said, you shouldn't have any issues using our Sencha Eclipse Plugin, even if you excluded the project, since we have separate parsing for autocompletion/etc. I have projects in eclipse which aren't even considered a "JavaScript" project, so the JSDT parsing/validation/etc isn't even enabled, and I'm able to use all of the Sencha plugin features.

There might be side effects if there was anything in JSDT you relied on, so let us know if that's the case.


On a quick side note. The plugin documentation doesn't describe if the user has to do anything special when the project is not using Sencha Cmd.Does the plugin work equally well on projects that use Sencha Cmd, and projects that don't?Do we need to do anything to our project, now that we don't use Sencha Cmd?Thanks

Once our GA release is available, you can use the following steps here and create a .sencha-ide-config file in the root of your project (http://docs.sencha.com/ide_plugins/eclipse_ide_plugin.html#_sencha_ide_config_file__optional_). You would just need to define the 'apps' section.
With the current EA release, we only supported the 'paths' configuration, which would allow you to add the SDK if it was outside of your project.

iver25
2 Dec 2015, 12:37 AM
A little update:I have tried the suggestions on StackOverflow, which helped tremendously on the copy issue. I stille have the issue where it takes forever to discover an error, and when I correct an error, it also takes a long time.I would like to try and exclude the SDK, and maybe the project, but I'm not sure how to do that. Do I use Window>Preferences>JavaScript>Include Path, and if so, how do I do it?Thanks.

Chris.OBrien
2 Dec 2015, 6:54 AM
A little update:I have tried the suggestions on StackOverflow, which helped tremendously on the copy issue. I stille have the issue where it takes forever to discover an error, and when I correct an error, it also takes a long time.I would like to try and exclude the SDK, and maybe the project, but I'm not sure how to do that. Do I use Window>Preferences>JavaScript>Include Path, and if so, how do I do it?Thanks.

Sorry about that, I thought I included a link to our documentation in my earlier reply about how you can exclude the SDK (or other folders) from Eclipse's JavaScript parsing.

Check out these instructions (http://docs.sencha.com/ide_plugins/eclipse_ide_plugin.html#Excluding_Ext_JS_SDK_from_Eclipse_s_JavaScript__optional_), which uses the Exclude Path on the project, not the global Window>Preferences.

Also, our GA release of the plugin is now officially available: https://www.sencha.com/forum/showthread.php?307147-Sencha-Eclipse-Plugin-is-Now-Generally-Available which you can get from the Sencha Support Portal. (It is coming soon to the Eclipse Marketplace)