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 61394 - "Open Project" gets messed up in team work
Summary: "Open Project" gets messed up in team work
Status: RESOLVED INVALID
Alias: None
Product: javaee
Classification: Unclassified
Component: Web Project (show other bugs)
Version: 4.x
Hardware: All All
: P1 blocker (vote)
Assignee: Radko Najman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-26 08:50 UTC by aripie
Modified: 2005-09-14 08:49 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description aripie 2005-07-26 08:50:17 UTC
Netbeans 4.1 sometimes refuses to open J2EE projects that have visited in 
Subversion. Project is edited by various programmers. These programmers use 
both Windows XP and Linux platforms.

We are using Subversion from command line (not from Netbeans) currently and we 
are aware that having those private.properties files messes up the whole 
project and we filter them away so that they do not go to the Subversion 
repository at all.

Still something goes occasionally totally wrong.
Projects sometimes get so messed that they simply do not open. That "Open 
Project" window does not find broken project and the small red Error icon 
appears on right bottom corner of the IDE. 

Projects get so messed that trying to fix them is nearly impossible. It is 
easier to make new project and stuff old code in ( or go backwards in 
versions ).

Is there any easier way to fix messed up project ?
Why do they get in that state ?
Is there anything we can do to avoid this ?

It seems at the moment impossible to use NetBeans in multiple programmer 
environment ( or are we just doing something wrong here ?)



Netbeans on Linux (and windows) sometimes gives Stack Overflow error when 
trying to Open Project. Perhaps after this projects go bad ...

Typically I get this Error in Windows when I try to open broken Project: 

Annotation: Exception occurred in Request Processor
java.lang.IllegalStateException: Attempt to call ProjectManager.findProject 
within the body of ProjectFactory.loadProject (hint: try using 
ProjectManager.mutex().postWriteRequest(...) within the body of your Project's 
constructor to prevent this)
	at org.netbeans.api.project.ProjectManager$2.run
(ProjectManager.java:189)
	at org.openide.util.Mutex.readAccess(Mutex.java:220)
	at org.netbeans.api.project.ProjectManager.findProject
(ProjectManager.java:176)
	at org.netbeans.spi.project.support.ant.ReferenceHelper$13.run
(ReferenceHelper.java:1557)
	at org.openide.util.Mutex.readAccess(Mutex.java:181)
	at 
org.netbeans.spi.project.support.ant.ReferenceHelper$RawReference.toAntArtifact
(ReferenceHelper.java:1542)
	at org.netbeans.spi.project.support.ant.ReferenceHelper$12.run
(ReferenceHelper.java:1143)
	at org.openide.util.Mutex.readAccess(Mutex.java:181)
	at 
org.netbeans.spi.project.support.ant.ReferenceHelper.findArtifactAndLocation
(ReferenceHelper.java:1120)
	at org.netbeans.modules.web.project.classpath.ClassPathSupport.itemsList
(ClassPathSupport.java:119)
	at 
org.netbeans.modules.web.project.classpath.WebProjectClassPathExtender.registerL
ibraryListeners(WebProjectClassPathExtender.java:229)
	at 
org.netbeans.modules.web.project.classpath.WebProjectClassPathExtender.<init>
(WebProjectClassPathExtender.java:70)
	at org.netbeans.modules.web.project.WebProject.<init>
(WebProject.java:248)
	at org.netbeans.modules.web.project.WebProjectType.createProject
(WebProjectType.java:42)
	at 
org.netbeans.modules.project.ant.AntBasedProjectFactorySingleton.loadProject
(AntBasedProjectFactorySingleton.java:133)
	at org.netbeans.api.project.ProjectManager.createProject
(ProjectManager.java:315)
	at org.netbeans.api.project.ProjectManager.access$700
(ProjectManager.java:43)
	at org.netbeans.api.project.ProjectManager$2.run
(ProjectManager.java:229)
	at org.openide.util.Mutex.readAccess(Mutex.java:220)
	at org.netbeans.api.project.ProjectManager.findProject
(ProjectManager.java:176)
	at org.netbeans.spi.project.support.ant.SubprojectProviderImpl$1.run
(SubprojectProviderImpl.java:67)
	at org.openide.util.Mutex.readAccess(Mutex.java:181)
	at 
org.netbeans.spi.project.support.ant.SubprojectProviderImpl.getSubprojects
(SubprojectProviderImpl.java:43)
	at 
org.netbeans.modules.project.ui.ProjectChooserAccessory.addSubprojects
(ProjectChooserAccessory.java:339)
	at org.netbeans.modules.project.ui.ProjectChooserAccessory.access$600
(ProjectChooserAccessory.java:52)
	at 
org.netbeans.modules.project.ui.ProjectChooserAccessory$ModelUpdater.run
(ProjectChooserAccessory.java:580)
	at org.openide.util.Task.run(Task.java:189)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330)
[catch] at org.openide.util.RequestProcessor$Processor.run
(RequestProcessor.java:721)
Comment 1 Jesse Glick 2005-08-01 19:26:44 UTC
Perhaps specific to web projects, but hard to evaluate without steps to
reproduce the problem from scratch.
Comment 2 aripie 2005-08-02 10:11:30 UTC
We had no idea either what generated this situation, but now it starts to clear 
up:

If Enterprise Application project is opened in other developer computer there 
seems to be "Reference problems" with WebModule of the project ( WebModule is 
red in IDE and misses some details about EJBModule ). 

Easy way to generate this situation:
Delete all private.properties files from the project and try to open it again.
or
Simply move project to different folder or rename the folder.


This problem is easily solved with right click on WebModule and giving the 
correct EJBMODULE in "Resolve Reference Problems ...". 

But what happens if poor programmer gives something else than EJBModule 
(project itself or WebModule) when trying to resolve reference problems ? 
NetBeans happily lets programmer get away with this and the whole project is 
mutilated into something that is really hard to fix.

After understanding this behaviour we have been able to use NetBeans in our 
project.

I am not sure if you see this as a bug or user problem, but I would like to 
suggest that following things could be fixed in future:

- Enterprise Application project should open without Reference Problems even 
private.properties files are deleted or if the project is copied to different 
folder. 

- In case there are Reference Problems there should be somekind of check that 
user action was at least to some degree right. 

- Wrong action in solving Reference Problems should not mess up the whole 
project.

Comment 3 zikmund 2005-08-08 10:02:45 UTC
Seems to be serious:

1) Have relative path to project which you are depending on - I have this
enhancement on my radar for 4.2

2) Improve 'Resolve References' checking of project types (we should file
separate issue for this)

Radko is there anything else we should improve in web sources?
Comment 4 Radko Najman 2005-08-08 10:12:39 UTC
Thank you for your report. I'll investigate it.
Comment 5 zikmund 2005-09-09 11:44:13 UTC
Good news: #1 has been fixed in trunk (5.0 daily builds)
           #2 has been filed - see issue 63960.
Comment 6 Radko Najman 2005-09-09 12:11:08 UTC
I tried to reproduce your problem in last few days but unsuccessfuly. I don't
use Subversion but I deleted private properties files and I also moved the
projects and it worked fine for me. I think this issue was fixed by issue
#63267. Could you try to reproduce your problem using the latest dev build, please?
Comment 7 Radko Najman 2005-09-14 08:49:39 UTC
No more feedback from the reporter -> closing. Feel free to reopen if the issue
is still valid.