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: | consider removing usage of MavenProject.getParent() | ||
---|---|---|---|
Product: | projects | Reporter: | Milos Kleint <mkleint> |
Component: | Maven | Assignee: | Milos Kleint <mkleint> |
Status: | RESOLVED FIXED | ||
Severity: | normal | Keywords: | PERFORMANCE |
Priority: | P3 | ||
Version: | 7.3 | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
Issue Type: | TASK | Exception Reporter: |
Description
Milos Kleint
2012-07-03 12:51:08 UTC
http://hg.netbeans.org/core-main/rev/ec35eae2bb89 MavenProject.getParent() replaced by NbMavenProjectImpl.loadParentOf() which reuses the configuration from current project and loads the parent (of parent,...) Some instances that called getParent() but used only trivial values from the result now use the MavenEmbedder.getModelDescriptors() call which returns data collected while loading the MavenProject because of fix of issue 215159, the attempt to call MavenProject.getParent() will result in thrown exception Integrated into 'main-golden', will be available in build *201207110002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/ec35eae2bb89 User: Milos Kleint <mkleint@netbeans.org> Log: #215159, #215127 clear projectBuildingRequest from Mavenproject instance which seems to b the point effectively referencing a RepositoryCache holding multiple Model object. Get rid of calls to MavenProject.getParent() and replace it with a method more suited for sparse invokations with throwaway results. Introduce ModelDescription to MavenEmbedder that contains various information collected while loading project's MavenProject, allowing to reduce the number of repeated queries to the embedder environment. |