dev@glassfish.java.net

Re: Odd, Semi-Reproducible Deployment Failure

From: Byron Nevins <Byron.Nevins_at_Sun.COM>
Date: Fri, 09 Mar 2007 15:12:24 -0800
AS is at the mercy of the OS when it comes to deleting files.  If Windows won't let YOU delete a file, then AS can't delete it either.
E.g. you open a DOS box in D:\java\glassfish\domains\domain1\applications\j2ee-apps\EngineeringWorkList   -- now you can't redeploy.  Try it.


Run handle.exe (
http://www.microsoft.com/technet/sysinternals/ProcessesAndThreads/Handle.mspx) like so:

handle EngineeringWork

it will show you every process that has handles open to a file with "
EngineeringWork" in its name.  You can NOT do a redeploy unless there are no open handles.


Jason Lee wrote:
Anyone?  Please? :P  I'm having trouble getting to deploy at all now.  It's not even on the target server, but the asadmin command is just staring back at me.  I'm seeing a bunch of entries like these:
 
[#|2007-03-09T16:00:10.851-0600|INFO|sun-appserver-pe9.0|javax.enterprise.system.util|_ThreadID=39;_ThreadName=Thread-3912;D:\java\glassfish\domains\domain1\applications\j2ee-apps\EngineeringWorkList;|UTIL6040: Error attempting to delete D:\java\glassfish\domains\domain1\applications\j2ee-apps\EngineeringWorkList|#]
 
[#|2007-03-09T16:00:10.851-0600|INFO|sun-appserver-pe9.0|javax.enterprise.system.util|_ThreadID=39;_ThreadName=Thread-3912;|UTIL6041: Performing gc to try to force file closures|#]
 
[#|2007-03-09T16:00:24.413-0600|INFO|sun-appserver-pe9.0|javax.enterprise.system.util|_ThreadID=39;_ThreadName=Thread-3912;D:\java\glassfish\domains\domain1\applications\j2ee-apps\EngineeringWorkList;4;|UTIL6043: Attempt to delete D:\java\glassfish\domains\domain1\applications\j2ee-apps\EngineeringWorkList failed after 4 retries|#]
 
-----
Jason Lee, SCJP
Senior Software Engineer
http://www.iec-okc.com
 


From: Jason Lee
Sent: Thursday, March 08, 2007 2:06 PM
To: dev@glassfish.dev.java.net
Subject: RE: Odd, Semi-Reproducible Deployment Failure

I should have posted this to dev as well, so here it is. :)
 
-----
Jason Lee, SCJP
Senior Software Engineer
http://www.iec-okc.com
 


From: Jason Lee
Sent: Thursday, March 08, 2007 12:13 PM
To: users@glassfish.dev.java.net
Subject: Odd, Semi-Reproducible Deployment Failure

I'm trying to deploy an ear that has multiple session beans, a web service, and a JSF app.  When I deploy, I somethings get:
 
deploy:
     [echo] ------------ Deploying C:\src\EngineeringWorkList\trunk/dist/ear/EngineeringWorkList.ear to Glassfish ------------
     [exec] CLI171 Command deploy failed : Deploying application in domain failed; Error loading deployment descriptors for module [EngineeringWorkList] -- Implementing class
     [exec]
 
from ant (which is just shelling out to asadmin.bat).  If I simple reissue the deploy command, it will eventually work with no changes made to the project.  I'm issuing "ant build package deploy" each time in case that matters (I know you don't know exactly what those targets do, but, in case it matters, you have a general feel for what I'm doing).  I've tried added "clean" to that list, but that doesn't seem to make a difference.  As best as I can tell, the relevant info from server.log is below.  Any ideas?  This happens on v2 b38 nightly as well as v1 ur1 p01.  Thanks!
 
 
[#|2007-03-08T12:08:04.373-0600|FINE|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=40;_ThreadName=Thread-91;ClassName=com.sun.enterprise.deployment.annotation.impl.ModuleScanner;MethodName=getElements;_RequestID=62fd64e9-6d57-404a-bff0-043a44cccd16;|Getting com.iecokc.worklist.engineering.service.EngineeringWorkListWebServiceImpl|#]
 
[#|2007-03-08T12:08:04.451-0600|FINE|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=40;_ThreadName=Thread-91;ClassName=com.sun.enterprise.deployment.backend.AppDeployer;MethodName=doRequestFinish;_RequestID=62fd64e9-6d57-404a-bff0-043a44cccd16;|Deployment Error
com.sun.enterprise.deployment.backend.IASDeploymentException: Error loading deployment descriptors for module [EngineeringWorkList] -- Implementing class
 at com.sun.enterprise.deployment.backend.Deployer.loadDescriptors(Deployer.java:364)
 at com.sun.enterprise.deployment.backend.AppDeployerBase.loadDescriptors(AppDeployerBase.java:345)
 at com.sun.enterprise.deployment.backend.AppDeployer.explodeArchive(AppDeployer.java:274)
 at com.sun.enterprise.deployment.backend.AppDeployer.deploy(AppDeployer.java:188)
 at com.sun.enterprise.deployment.backend.AppDeployer.doRequestFinish(AppDeployer.java:132)
 at com.sun.enterprise.deployment.phasing.J2EECPhase.runPhase(J2EECPhase.java:174)
 at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:95)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:892)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:266)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:761)
 at com.sun.enterprise.management.deploy.DeployThread.deploy(DeployThread.java:174)
 at com.sun.enterprise.management.deploy.DeployThread.run(DeployThread.java:210)
Caused by: java.lang.IncompatibleClassChangeError: Implementing class
 at java.lang.ClassLoader.defineClass1(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
 at com.sun.enterprise.loader.EJBClassLoader.findClass(EJBClassLoader.java:674)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
 at com.sun.enterprise.deployment.annotation.impl.ModuleScanner.getElements(ModuleScanner.java:161)
 at com.sun.enterprise.deployment.archivist.Archivist.processAnnotations(Archivist.java:392)
 at com.sun.enterprise.deployment.archivist.Archivist.readAnnotations(Archivist.java:333)
 at com.sun.enterprise.deployment.archivist.Archivist.readDeploymentDescriptors(Archivist.java:305)
 at com.sun.enterprise.deployment.archivist.Archivist.open(Archivist.java:200)
 at com.sun.enterprise.deployment.archivist.ApplicationArchivist.readModulesDescriptors(ApplicationArchivist.java:308)
 at com.sun.enterprise.deployment.backend.Deployer.loadDescriptors(Deployer.java:318)
 ... 11 more
|#]
 
[#|2007-03-08T12:08:04.451-0600|FINE|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=40;_ThreadName=Thread-91;ClassName=com.sun.enterprise.deployment.backend.Deployer;MethodName=finish;_RequestID=62fd64e9-6d57-404a-bff0-043a44cccd16;|Total Deployment Time: 4000 msec, Total EJB Compiler Module Time: 0 msec, Portion spent EJB Compiling: 0%|#]
 
[#|2007-03-08T12:08:04.451-0600|FINER|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=40;_ThreadName=Thread-91;ClassName=com.sun.enterprise.deployment.backend.Deployer;MethodName=finish;_RequestID=62fd64e9-6d57-404a-bff0-043a44cccd16;||#]
 
[#|2007-03-08T12:08:04.483-0600|WARNING|sun-appserver9.1|javax.enterprise.system.tools.verifier|_ThreadID=40;_ThreadName=Thread-91;_RequestID=62fd64e9-6d57-404a-bff0-043a44cccd16;|domainxmlverifier.error_on_validation
java.lang.NullPointerException
 at com.sun.enterprise.config.serverbeans.validation.GenericValidator.getConfigElementPrintName(GenericValidator.java:382)
 at com.sun.enterprise.config.serverbeans.validation.GenericValidator.getTargetElementPrintName(GenericValidator.java:399)
 at com.sun.enterprise.config.serverbeans.validation.GenericValidator.initialize(GenericValidator.java:94)
 at com.sun.enterprise.config.serverbeans.validation.GenericValidator.validate(GenericValidator.java:336)
 at com.sun.enterprise.config.serverbeans.validation.tests.DeployableAppTest.validate(DeployableAppTest.java:49)
 at com.sun.enterprise.config.serverbeans.validation.tests.J2eeApplicationTest.validate(J2eeApplicationTest.java:42)
 at com.sun.enterprise.config.serverbeans.validation.DomainMgr.check(DomainMgr.java:317)
 at com.sun.enterprise.config.serverbeans.validation.DomainMgr.preChangeNotification(DomainMgr.java:339)
 at com.sun.enterprise.config.impl.ConfigContextImpl.change(ConfigContextImpl.java:934)
 at com.sun.enterprise.config.impl.ConfigContextImpl.preChange(ConfigContextImpl.java:905)
 at com.sun.enterprise.config.ConfigBean.preConfigChange(ConfigBean.java:888)
 at com.sun.enterprise.config.ConfigBean.preConfigChange(ConfigBean.java:879)
 at com.sun.enterprise.config.ConfigBean.preRemoveValue(ConfigBean.java:871)
 at com.sun.enterprise.config.ConfigBean.removeValue(ConfigBean.java:373)
 at com.sun.enterprise.config.ConfigBean.removeValue(ConfigBean.java:356)
 at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.removeModule(DeploymentServiceUtils.java:1597)
 at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.removeFromConfig(DeploymentServiceUtils.java:757)
 at com.sun.enterprise.deployment.phasing.J2EECPhase.runPhase(J2EECPhase.java:228)
 at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:95)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:892)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:266)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:761)
 at com.sun.enterprise.management.deploy.DeployThread.deploy(DeployThread.java:174)
 at com.sun.enterprise.management.deploy.DeployThread.run(DeployThread.java:210)
|#]
 
[#|2007-03-08T12:08:04.514-0600|SEVERE|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=40;_ThreadName=Thread-91;_RequestID=62fd64e9-6d57-404a-bff0-043a44cccd16;|Exception occured in J2EEC Phase
com.sun.enterprise.deployment.backend.IASDeploymentException: Error loading deployment descriptors for module [EngineeringWorkList] -- Implementing class
 at com.sun.enterprise.deployment.backend.Deployer.loadDescriptors(Deployer.java:364)
 at com.sun.enterprise.deployment.backend.AppDeployerBase.loadDescriptors(AppDeployerBase.java:345)
 at com.sun.enterprise.deployment.backend.AppDeployer.explodeArchive(AppDeployer.java:274)
 at com.sun.enterprise.deployment.backend.AppDeployer.deploy(AppDeployer.java:188)
 at com.sun.enterprise.deployment.backend.AppDeployer.doRequestFinish(AppDeployer.java:132)
 at com.sun.enterprise.deployment.phasing.J2EECPhase.runPhase(J2EECPhase.java:174)
 at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:95)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:892)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:266)
 at com.sun.enterprise.deployment.phasing.PEDeploymentService.deploy(PEDeploymentService.java:761)
 at com.sun.enterprise.management.deploy.DeployThread.deploy(DeployThread.java:174)
 at com.sun.enterprise.management.deploy.DeployThread.run(DeployThread.java:210)
Caused by: java.lang.IncompatibleClassChangeError: Implementing class
 at java.lang.ClassLoader.defineClass1(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
 at com.sun.enterprise.loader.EJBClassLoader.findClass(EJBClassLoader.java:674)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
 at com.sun.enterprise.deployment.annotation.impl.ModuleScanner.getElements(ModuleScanner.java:161)
 at com.sun.enterprise.deployment.archivist.Archivist.processAnnotations(Archivist.java:392)
 at com.sun.enterprise.deployment.archivist.Archivist.readAnnotations(Archivist.java:333)
 at com.sun.enterprise.deployment.archivist.Archivist.readDeploymentDescriptors(Archivist.java:305)
 at com.sun.enterprise.deployment.archivist.Archivist.open(Archivist.java:200)
 at com.sun.enterprise.deployment.archivist.ApplicationArchivist.readModulesDescriptors(ApplicationArchivist.java:308)
 at com.sun.enterprise.deployment.backend.Deployer.loadDescriptors(Deployer.java:318)
 ... 11 more
|#]
 
 
 
-----
Jason Lee, SCJP
Senior Software Engineer
http://www.iec-okc.com