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.
Summary: | Delay writing of Nb platform to global properties | ||
---|---|---|---|
Product: | apisupport | Reporter: | Jaroslav Tulach <jtulach> |
Component: | Project | Assignee: | rmichalsky <rmichalsky> |
Status: | RESOLVED FIXED | ||
Severity: | blocker | CC: | issues |
Priority: | P3 | Keywords: | PERFORMANCE |
Version: | 6.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: | |
Bug Depends on: | 169448 | ||
Bug Blocks: | |||
Attachments: |
Suggested fix
Corrected patch without System.err |
Description
Jaroslav Tulach
2009-07-21 12:04:24 UTC
Created attachment 84996 [details]
Suggested fix
1) Test setup is the culprit here, this doesn't happen to real user. Tested IDE has userdir somewhere under test work dir, thus it is owned by NB.org module project, which then gets (IMHO needlessly) loaded by PHP project support. 2) I'm not 100% sure that the stored property is actually not needed before NbPlatform is loaded (although you are probably right), and I don't have time to investigate it. Given 1) I'd suggest to fix test setup instead or WONTFIX. You are right the test setup influences the fact that the NbModuleProject is created. This would not happen in real user scenario. On the other hand, this issue claims that API Support writes down the global properties file prematurely, which is true even in the user scenario. We don't want users to pay price for feature they don't use, thus the report remains valid. Obviously I cannot confirm that NbPlatform is loaded everytime the property would be needed. Although I can guarantee that the class is loaded as soon as NbModuleProject or NbSuiteProject is opened. It is obviously up to you to decide whether you want to leave this bug open or apply the patch as soon as possible (so potential problems are revealed soon before release). I will investigate the issue with PHP visibility query and think about ways to improve the test (though I do not have any reasonable idea right now). Created attachment 85052 [details]
Corrected patch without System.err
The patch looks reasonable to me (though Install.java should just be deleted altogether). Should defer writing the NB platform unless and until someone actually works with an NBM project. core-main#c759aee432d6 Integrated into 'main-golden', will be available in build *200907241401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/c759aee432d6 User: Jaroslav Tulach <jtulach@netbeans.org> Log: #168874: Don't initialize apisupport prematuraly - wait until someone really uses it, e.g. loads NbPlatform class. Approved by Jesse and Richard. |