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.
against GF v2 b58g steps to reproduce 1. create an ent app with a web app 2. add struts to the web app 3. change the welcome file list to open welcomeStruts.jsp by default for the web app 4. run the app... the app deploys and runs and appears in the browser 5. make a change to the web app (optional) 6. use the 'Undeploy and Deploy' action. See... ... post-dist: dist: pre-run-deploy: Undeploying ... While undeploying, trying to stop application in target server completed successfully While undeploying, trying to remove reference for application in target server completed successfully Undeploying the application Trying to undeploy application from domain completed successfully Undeployment of application EnterpriseApplication2 completed successfully All operations completed successfully Initial deploying EnterpriseApplication2 to C:\Users\vbk\Documents\NetBeansProjects\EnterpriseApplication2\dist\gfdeploy Error during incremental deploy: org.netbeans.modules.masterfs.filebasedfs.utils.FSException: Cannot delete file antlr.jar in C:/Users/vbk/Documents/NetBeansProjects/EnterpriseApplication2/dist/gfdeploy. Start registering the project's server resources Finished registering server resources Deployment error: null See the server log for details. at org.netbeans.modules.j2ee.deployment.devmodules.api.Deployment.deploy(Deployment.java:163) at org.netbeans.modules.j2ee.ant.Deploy.execute(Deploy.java:104) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288) at sun.reflect.GeneratedMethodAccessor481.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:105) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:357) at org.apache.tools.ant.Target.performTasks(Target.java:385) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329) at org.apache.tools.ant.Project.executeTarget(Project.java:1298) at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41) at org.apache.tools.ant.Project.executeTargets(Project.java:1181) at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:277) at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:460) at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:151) Caused by: java.lang.NullPointerException at org.netbeans.modules.j2ee.sun.bridge.DirectoryDeployment.initialDeploy(DirectoryDeployment.java:320) at org.netbeans.modules.j2ee.sun.ide.j2ee.incrdeploy.DirectoryDeploymentFacade.initialDeploy(DirectoryDeploymentFacade.java:210) at org.netbeans.modules.j2ee.deployment.impl.TargetServer.deploy(TargetServer.java:508) at org.netbeans.modules.j2ee.deployment.devmodules.api.Deployment.deploy(Deployment.java:148) ... 16 more BUILD FAILED (total time: 0 seconds)
it looks like the root cause is the use of delete() in InitialServerFileDistributor.java
Created attachment 54704 [details] first pass at a patch
Vince, can you elaborate bit more on the steps to reproduce please? I'm probably doing something wrong and I'm not able to reproduce it. Thanks.
are you using Windows? That is the most important step. At step four: use the Run item from the project's right-click menu. You need to see the output of the welcomeStruts.jsp page in the browser. At step six: use the 'Undeploy and Deploy' item from the project's right-click menu.
Created attachment 54779 [details] new patch
Notes on the new patch: 1. try to limit the work-around to windows only 2. try to overwrite jar and zip files that may be present... this is to try to prevent bleed through of old into new deployment. I am not sure that old stuff could slip back into a deployment (say if you changed the name of a jar).
*** Issue 116790 has been marked as a duplicate of this issue. ***
This is a bit suspicious - standalone webapp works fine, while webapp as a part of ear requires this workaround (maybe it is not stopped before).
When I follow the steps server has some trouble with deployment of the webapp. When the application is undeployed (after that) the log shows the message "[WebContainer] Undeployment failed for context /EnterpriseApplication2-war " and deployment fails with the stacktrace. Probably due to this the libs remains locked. Will investigate further.
stand-alone fine; ear with struts has problem: Part of the reason for this is the stand-alone case doesn't have to go through this copy everything to a new directory process.
Created attachment 54880 [details] patch without need of binary file, some other issues fixed
If no objections, I will integrate the patch tomorrow morning.
I will put it through its paces today. Your version is much cleaner... thanks.
my windows box has gotten corrupted... so i won't be able to test this today. I was seeing issues with my version of this last night... but they were in an environment where I also saw issue 124973... I don't trust the environment at this point....
Fixed. Maybe better solution could be to deploy to another dir when the jars are locked - just an idea, I'm not sure if it can be done in a clean way. Checking in InitialServerFileDistributor.java; /cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/InitialServerFileDistributor.java,v <-- InitialServerFileDistributor.java new revision: 1.24; previous revision: 1.23 done
finally got a rebuilt environment. all good.
Tried over daily 200801220000 & GF v2 ur1 & jdk 1.6 u3 on windows/xp But I cannot do the Run of the ear at step 4. With Run (project) or Undeploy&Deploy, I'm getting a "Parsing error processing resource path /WEB-INF/struts-config.xml" When I added struts Framework to the web App I've check the box Add Truts TLDs. The deployment (Run, UndeployDeploy & Run many times) of the web application with struts 1.2.9 has no issue. Joining the server log file in the attachement.
Created attachment 55368 [details] gf v2 ur1 server log file with the exceptions
Tried again with another ear and web + struts in which I did not check the tld box, got the same error for the ear deployment (web module) in 4.
adding myself in cc to receive the notification.
Created attachment 55370 [details] message.log with many warnings messages
nouar, behaviour you describe is the issue 116370
that's right I've looked to 116370, so how can this one be verified ? the two ones are related ?
use 'undeploy and deploy' on an ear that doesn't have a 'space in path'. For example: c:\Users\vbk\Documents\NetBeansProjects\Test124728 instead of c:\Documents and Settings\vbk\Documents\NetBeansProjects\Test124728...
ok tried over an ear project created in c:\temp\EntAppTest124728 and all the steps described in the Description are done with success, did 4/6, 5 times and all are ok. thanks.
I have dont have spaces in my netbeansprojects folder path, but I still get the error. Issue was marked verified fixed, what is the fix for it? do we have to download 6.1m1? download a patch?
you would need to get a build of NetBeans 6.1 created after Jan 10, 2008. I have flagged this fix as a candidate for the next round of updates to NetBeans 6.0.1.
The fix has been ported into the release601_fixes branch. Checking in InitialServerFileDistributor.java; /cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/Attic/InitialServerFileDistributor.java,v <-- InitialServerFileDistributor.java new revision: 1.22.10.1; previous revision: 1.22 done