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.
NetBeans 5.5 Preview (Build 200602012300) When deploying a web application via F6 (The run button), if the project is located on a path containing spaces, the entity manager factory will not be created correctly due to the spaces present in the path to the build/web/WEB-INF/classes directory. When deployed manually as a .war, the problem goes away. I'm sure people will like to throw this back and forth with the Glassfish project, however NetBeans is implementing the rapid (re)deployment.
Also, when moving the project to a path without spaces, everything works again
Could you please send a more detailed description of how to reproduce this issue and what exactly do you mean by "the entity manager factory will not be created"?
OK. This is not the smallest test case. Start with a clean install of NetBeans 5.5 Preview 1. Register a local glassfish server 2. Create a new EJBable project save it in a directory that has spaces in the path name (let's use WebApplication and put it in C:\Documents and Settings\test case\WebApplication1) 3. Add a persistence unit 4. Add a EJB3 entity (Quick way, pick any database table that is there and use the wizard to create an entity based on the table) First test point 5. At this point, if you try to deploy using the Run command (assigned to key F6), you will get a deployment failure. But take the .war file and deploy it manually and the web application deploys fine. 6. Add a page that uses the entities (quick way, use the JSF page wizard) Second test point 7. Again should still have the failure with the Run command (assigned to key F6). 8. Move the project to a location wihout spaces in the path (e.g. c:\test_case\WebApplication1 9. At this point, you can now deploy using the Run command (assigned to key F6) Note: They key binding is irrelevant to the issue. The issue is irrespective of the method of invoking the Run command (I'm just using the key binding to clearly identify the command in question) Hope this helps
> what exactly do you mean by "the entity manager factory will not be created"? If you look in the server log file, you will find that there are problems creating the entity manager factory due to (i'm guessing) spaces in the classpath. The spaces arrise when (i'm guessing again) netbeans modifies the classpath to include a reference to the project folder where the expanded classes are ready for deployment. Because the application server does not use a copy of the files and instead uses them in situ, the spaces will be necessarily in the classpath for this app. The classpath for the app is in an order such that the classloader can no longer find the entity manager factory and therefore deployment issues arrise
moving to sunappserv module for evaluation
Vince: try and check with app server backend folks if necessary.
this is really something that should be p2, though the fix may have to be in the GlassFish codebase.
I ran problem when I rapid deployment or redeployment on cmpcustomer (j2ee1.4 cmp sample) in windows XP with a space in the appserver install directory. There is one time I saw the following error ADMVAL1052 in server.log, but there are other times IDE hungs or deployment failed, but I could not recreat this. Most time it works fine. I talked with GlassFish developer and they said the ADMVAL1052 is caused by window file lock issue, but without be able to recreate it consistantly, developer said it is very hard to know what is the problem. The problem I saw may not be the same as this one reported, but the space in the path is the same environment I use, also it seems at the time when I hit this problem, I was hitting the deploy function very fast. Just another information for developer. ---------- There is this error in the server.log when I deploy the cmpcustomer (j2ee1.4 cmp sample), but after I undeploy the cmp app, then deploy the app, it worked fine. It is regarding "Could not rename" UTIL6046: Attempt to rename D:\AppServer Install\9sdkplus\domains\domain1\applications\j2ee-apps\cmpcustomer to D:\AppServer Install\9sdkplus\domains\domain1\applications\j2ee-apps\cmpcustomer_old failed after 4 retries Validation error: [ADMVAL1052: Element j2ee application 'cmpcustomer' can not be deleted because it is referenced from server 'server'] Exception occured in J2EEC Phase com.sun.enterprise.deployment.backend.IASDeploymentException: Could not rename D:\AppServer Install\9sdkplus\domains\domain1\applications\j2ee-apps\cmpcustomer to D:\AppServer Install\9sdkplus\domains\domain1\applications\j2ee-apps\cmpcustomer_old at com.sun.enterprise.deployment.backend.AppReDeployer.setAppDirArchive(AppReDeployer.java:333) at com.sun.enterprise.deployment.backend.AppReDeployer.setAppDir(AppReDeployer.java:139) at com.sun.enterprise.deployment.backend.AppDeployerBase.predeploy(AppDeployerBase.java:147) at com.sun.enterprise.deployment.backend.AppDeployer.predeploy(AppDeployer.java:161) at com.sun.enterprise.deployment.backend.AppReDeployer.predeploy(AppReDeployer.java:127) at com.sun.enterprise.deployment.backend.AppDeployer.doRequestFinish(AppDeployer.java:128) at com.sun.enterprise.deployment.phasing.J2EECPhase.runPhase(J2EECPhase.java:169) at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:95) at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:871) at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:266) at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:739) at com.sun.enterprise.management.deploy.DeployThread.deploy(DeployThread.java:174) at com.sun.enterprise.management.deploy.DeployThread.run(DeployThread.java:210) |#]
I attempted to reproduce this issue and was not able to (GFv1b48/SJSASPE90 with NB 5.5 Beta). I started to dig into the fixed bugs list for GF and came up with these: https://glassfish.dev.java.net/issues/show_bug.cgi?id=184 https://glassfish.dev.java.net/issues/show_bug.cgi?id=228 https://glassfish.dev.java.net/issues/show_bug.cgi?id=485 closing