Netbeans performance issues with 0.10.0-RCx #315

Closed
lombokissues opened this Issue Jul 14, 2015 · 24 comments

Projects

None yet

1 participant

@lombokissues
Collaborator

Migrated from Google Code (issue 242)

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Jul 27, 2011 at 17:05 UTC

What steps will reproduce the problem?

  1. Install jar in classpath

What is the expected output? What do you see instead?
Everything should work basically the same as for b2

What version of the product are you using? On what operating system?
0.10.0-RC2 (although happened with RC1 too) on Ubuntu 10.10 and Netbeans 7.0.

Please provide any additional information below.
I wish I could be more specific, but it's hard to isolate the issue with my codebase which, while not huge, is not trivially small either. Basically, after working for ten or fifteen minutes with the new version, Netbeans becomes a dog. It looks like the problem is memory usage. A restart of netbeans clears things up for awhile.

@lombokissues
Collaborator

๐Ÿ‘ค reinierz ย  ๐Ÿ•— Aug 01, 2011 at 22:04 UTC

Because the changes between 0.9 and 0.10 are very large, I don't think an analysis of what we've been changing is the right way to go about it. We'll look at running netbeans in a profiler to find the leak. Any help in this area would be appreciated :)

Will probably not be fixed for 0.10.0. (certainly not for RC3 which will be rolled out tonight).

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Aug 02, 2011 at 03:37 UTC

Awesome, thanks. I'm happy to help if you can tell me what to look for. I'd love for it to be fixed for 0.10.0 so that I can use it. :-)

@lombokissues
Collaborator

๐Ÿ‘ค Lord.Quackstar ย  ๐Ÿ•— Aug 02, 2011 at 10:52 UTC

Quick question, are you sure its not Netbeans being Netbeans? No matter what version NB I use its always hemorrhaged memory, I usually restart every hour or so to fix it

@lombokissues
Collaborator

๐Ÿ‘ค pe.fips ย  ๐Ÿ•— Aug 02, 2011 at 13:17 UTC

I see that you've used Netbeans 7.0. Please upgrade to Netbeans 7.0.1 and let us know if you still get these hick-ups.

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Aug 02, 2011 at 17:48 UTC

I'm not absolutely positive that the problem isn't Netbeans, but 7.0 has been much better than past versions, and normally I rarely have to restart it. I just got the announcement for 7.0.1, so I'll definitely try that out and report back.

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Aug 08, 2011 at 22:24 UTC

No change with 7.0.1 and lombok 0.10 rc3. I can go about 30 minutes and then have to restart; this was not the case with the beta versions of .10.

@lombokissues
Collaborator

๐Ÿ‘ค pe.fips ย  ๐Ÿ•— Aug 09, 2011 at 00:00 UTC

Ok this means we have to look into it. Thanks for the feedback.

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Aug 09, 2011 at 03:44 UTC

No problem. If there's something I can do on my end that will help pinpoint the issue, just let me know.

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Aug 18, 2011 at 20:26 UTC

I'm not positive, but I'm noticing that the performance issues seem to occur when I have a source file open that uses the @ Cleanup annotation.

@lombokissues
Collaborator

๐Ÿ‘ค MrNarve ย  ๐Ÿ•— Oct 17, 2011 at 21:10 UTC

Any news on this one? I'd like to report my experience: After 30-60 minutes Netbeans becomes more or less unusable. Also, there is a bug (either in NB or Lombok) that makes autogeneration of code in Netbeans fail. Instead of inserting e.g. a getter or a method skeleton it inserts the whole class (or at least most of it, starting from top of source file). Very annoying.

I don't use Cleanup - usually Data or one of the "subsets" of Data, especially EqualsAndHashCode.

My versions: Netbeans 7.0.1, Windows764bit, Lombok 0.10.1.

Regarding memory usage: I use NB every day on much larger projects, it handles those well (almost as well as IntelliJ actually!). It also handles other source files in same project well. It seems to be only while editing files containing Lombok annotations that these problems occurs.

@lombokissues
Collaborator

๐Ÿ‘ค grootjans ย  ๐Ÿ•— Nov 07, 2011 at 22:21 UTC

At this moment, none of the direct lombok committers work on Netbeans. We only have smaller test project, and we don't run these for any significant amount of time. So the chance of us running into these issues are small to none.

However, if someone with a Netbeans background would be willing to profile his application, and do a heapdump when it gets slow. The heapdump would give us an overview of what kind of instances have been created and give us a target for a fix (Object type Foo was created X bazillion times)

To profile your netbeans, try pointing jvisualvm (supplied with every JDK since 1.6.10+).

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Nov 07, 2011 at 23:58 UTC

You bet. I've got one all ready for you, but it's 166 meg compressed. How should I get it to you?

@lombokissues
Collaborator

๐Ÿ‘ค MrNarve ย  ๐Ÿ•— Nov 08, 2011 at 09:12 UTC

You beat me to it, gbier! I'll create another heapdump if needed.

@lombokissues
Collaborator

๐Ÿ‘ค jirka.hana ย  ๐Ÿ•— Nov 13, 2011 at 19:41 UTC

I have the same experience (currently it uses 800 MB), I do not have this problem with a much larger project not using lombok. I attach the memory histogram. The heap dump is 1GB (uncompressed), should I post it somewhere?

Although the memory leak might be in the Netbeans support for annotation processors.

Using NB 7.0.1. fully updated today, lombok v0.10.1.

@lombokissues
Collaborator

๐Ÿ‘ค jirka.hana ย  ๐Ÿ•— Nov 13, 2011 at 19:41 UTC

๐Ÿ”— histoLive.zip

@lombokissues
Collaborator

๐Ÿ‘ค haakonn ย  ๐Ÿ•— Nov 14, 2011 at 14:03 UTC

I'm seeing these problems as well, running Lombok 0.10.2 under Netbeans 7.1-snapshot on Ubuntu 11.10. I can barely go 30 minutes without having to kill Netbeans and restart it. I'm only using @ Data, @ ToString, @ EqualsAndHashCode, and the constructor annotations. Sorry I can't be more concrete right now, just adding my voice.

@lombokissues
Collaborator

๐Ÿ‘ค jonathancrosmer@hotmail.com ย  ๐Ÿ•— Nov 20, 2011 at 20:42 UTC

I have this problem running Lombok 0.10.2 in Netbeans 7.1 beta Windows 7. Enabling annotation processing in editor suddenly triples my NB memory usage and eventually it becomes unusable.

@lombokissues
Collaborator

๐Ÿ‘ค jirka.hana ย  ๐Ÿ•— Nov 24, 2011 at 07:30 UTC

The problem does not occur when I use Lombok v0.9.3.

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Dec 06, 2011 at 22:50 UTC

Hi grootjans,

I appreciate your interest in taking a look at this. At this point it looks like three people, including me, have offered to provide heap dumps. Where would you like them (since they're too big to attach)?

Cheers,
Gann

@lombokissues
Collaborator

๐Ÿ‘ค grootjans ย  ๐Ÿ•— Dec 15, 2011 at 12:11 UTC

We did some analysis on netbeans by doing heapdumps during editing. We found a possible culprit, a weakhashmap whose values seemed to reference the keys. Did another round of heapdumps to confirm that the fix improved the situation.

pushed in: 306a9ef

A new EDGE-release with the fix is here: https://projectlombok.org/download-edge.html

@lombokissues lombokissues removed the accepted label Jul 14, 2015
@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Dec 15, 2011 at 17:20 UTC

Fabulous-- thank you! I'm trying it out now.

@lombokissues
Collaborator

๐Ÿ‘ค gbierner ย  ๐Ÿ•— Dec 21, 2011 at 22:31 UTC

I've used it for about a week now and this seems to have solved the problem. What a relief! Thanks so much!

@lombokissues
Collaborator

End of migration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment