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.

Bug 190849 - Go to Type is not refreshing maven projects
Summary: Go to Type is not refreshing maven projects
Status: RESOLVED INVALID
Alias: None
Product: projects
Classification: Unclassified
Component: Maven (show other bugs)
Version: 7.0
Hardware: PC Other
: P3 normal (vote)
Assignee: Jesse Glick
URL:
Keywords:
Depends on:
Blocks: 192647
  Show dependency tree
 
Reported: 2010-10-08 13:13 UTC by onmomo
Modified: 2012-02-14 17:53 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
maven projects & screenshots for reproducing (3.71 MB, application/zip)
2010-10-09 14:27 UTC, onmomo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description onmomo 2010-10-08 13:13:20 UTC
I searched for a class which was placed in an opend maven project in the IDE with the Go to type dialog and found it probably. After that I closed the maven project and searched again for the class. I've found the class again but unfortunately the location path still showed the path to the local sources instead the path to the project jar located in the local repository which is wrong.
After a restart, the go to type dialog worked as expected.

Used Build: NB 6.10-m1
Comment 1 Jesse Glick 2010-10-08 16:20:59 UTC
Need steps to reproduce from scratch. What exactly did you do, and what exactly did you see (e.g. screenshots)?
Comment 2 onmomo 2010-10-09 14:27:28 UTC
Created attachment 102331 [details]
maven projects & screenshots for reproducing

correct.png shows the state when you load those projects in the ide.

bug.png shows the state after you closed mavenprojectB in search for class "SearchTarget". The location path is wrong, should be repository jar path.

correct-restart.png shows the state after a restart of the IDE and search for "SearchTarget" --> location path points to repository --> was correct refreshed only after restart.
Comment 3 Jesse Glick 2010-10-09 15:21:15 UTC
I will try to reproduce when I get a chance.
Comment 4 Milos Kleint 2012-02-07 08:43:43 UTC
from what I read in MavenFileOwnerQueryImpl class, the registered coordinates are never removed, unless there is some problem with loading the underlying project object (which is not the case for just closed projects)
Comment 5 Jesse Glick 2012-02-14 17:52:09 UTC
(In reply to comment #2)
> bug.png shows the state after you closed mavenprojectB in search for class
> "SearchTarget". The location path is wrong, should be repository jar path.

No, this screenshot is correct - Go to Type works on transitive dependencies of open project, and since A depends on B using a snapshot version, B/src/main/java/ is used as the definition of types in this project, even if it is not open.

> correct-restart.png shows the state after a restart of the IDE and search for
> "SearchTarget"

When I try the same, I continue to see the source file from B/src/main/java/ as expected.
Comment 6 Jesse Glick 2012-02-14 17:53:25 UTC
BTW this was filed against 7.0 where the behavior of MFOQI was different than it is in 7.1+.