This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
As discussed with java/editor team, we should try to prevent timestamp checks of class files for unchanged source roots. See section up-to-date check: http://wiki.netbeans.org/JavaScanDesc. It shows maximum improvement when no changes were done in source roots. How it works: During the source root scanning, it collects java file names and its timestamps. When it is finished, md5 is computed from collected data and stored in attributes.properties file in appropriate index directory. When already stored, it compares the computed and stored digest. If they are the same, it skips listing and timestamp checking of class files. Moreover, the source level is part of digest computation to allow rescanning when source level for a root is changed.
Created attachment 64939 [details] Patch
Honza Pokorsky has found that when sources are opened in editor, after restart they are incorrectly underlined. This is because of usages index was not initialized. Adding initialization of index should help. (Tomas Z.)
Created attachment 65497 [details] Updated patch #1
Applied. changeset a15dd771a170 in main
Integrated into 'main-golden', available in build *200807311401* on http://bits.netbeans.org/dev/nightly/ Changeset: http://hg.netbeans.org/main/rev/a15dd771a170 User: Pavel Flaska <pflaska@netbeans.org> Log: #140680: Skip class-file timestamp checking when no needed. Test included.
A similar technique could be used to avoid scanning of dependent projects when external libraries have changed: save a checksum of an Public-API listing of an external lib (as provided e.g. by javap). If unchanged skip recompiling/scanning dependent projects and sources. Frank-Michael