vralfy / phpcsmd

Netbeans plugin to report code measurements generated by phpcs, phpmd, phpcpd and pdepend as Tasks and Annotations
27 stars 6 forks source link

org.openide.filesystems.FileObject.toURL: LowPerformance took 72521 ms. #34

Closed vralfy closed 10 years ago

vralfy commented 10 years ago

From https://netbeans.org/bugzilla/show_bug.cgi?id=238237

User Comments: jerry.lindahl: Opened a PHP file in Files explorer. File is part of a pretty large project. 100% cpu usage while being frozen. Happens often and is why I tried the development version. Can also happen when:ctrl click on function name, find usages or using other features that do some sort of project scannning.


Method de.foopara.phpcsmd.generics.GenericAnnotationBuilder.annotateLine() calls LineCookie.getLineSet().getLines().size(), which is quite slow, in EDT.

I'm not sure it can be fixed in openide.text (see bug 223634), but it can be probably fixed in the plugin (if LineSet is processed in a background thread).

Reassigning to owner to the plugin. Please evaluate it. Thank you.

daangemist commented 10 years ago

Is there any update on this issue? Or is there a way I can assist in getting this issue resolved?

vralfy commented 10 years ago

Im working on it ... I am going to run annotations in an extra thread. If you know a faster way to annotate lines let me know it

vralfy commented 10 years ago

Theading is done ... could someone check these changes? ... I forgot to mention this issue in the previous commit

daangemist commented 10 years ago

Hi, I have been using the plugin all day now, with "update on save" turned on and have not encountered any problems yet. It seems to be working.

vralfy commented 10 years ago

Great ... i will upload a new version on netbeans.org in a few days