- This topic has 5 replies, 2 voices, and was last updated 18 years, 10 months ago by Riyad Kalla.
-
AuthorPosts
-
zambizziMemberI’m using Eclipse 3.1.2, MyEclipse 4.1.1, and JBoss 4.0.4RC1. I’ve created an EAR project w/ a single EJB, EAR, and web project.
I’ve got my project set to deploy everything as jars but setting it to smart deploy doesn’t fix my problem…things just don’t get deployed automatically at all.
That’s fine, I’d prefer to deploy the EAR manually but my problem is; I get an exception when doing a hot re-deploy and have to restart the server every time, which is a *total* drag since JBoss takes a week to restart!
BTW – I’m deploying it as an exploded archive.
When I use a regular (non-EAR) web project w/ JBoss I don’t have this problem…no exceptions and everything re-deploys w/o a single problem. However, w/ this EAR project, I see this message in the “Deployment Status” area in the Project Deployments dialog:
“Undeployment failure on JBoss 4. File C:\Program Files\etc\etc…unable to be deleted. If a file is locked, you can wait until the lock times out to redeploy, or stop the server and redeploy, or manually remove the deployment at C:\Program Files\etc\etc”
I see this exception in the output:
12:24:39,264 INFO [SessionFactoryImpl] closing 12:24:39,274 INFO [EARDeployer] Undeploying J2EE application, destroy step: file:/C:/Program Files/jboss-4.0.4RC1/server/default/deploy/MyEAR.ear/ 12:24:39,274 INFO [EARDeployer] Undeployed J2EE application: file:/C:/Program Files/jboss-4.0.4RC1/server/default/deploy/MyEAR.ear/ 12:24:39,274 INFO [EARDeployer] Init J2EE application: file:/C:/Program Files/jboss-4.0.4RC1/server/default/deploy/MyEAR.ear/ 12:24:39,274 ERROR [MainDeployer] Could not initialise deployment: file:/C:/Program Files/jboss-4.0.4RC1/server/default/deploy/MyEAR.ear/ org.jboss.deployment.DeploymentException: No META-INF/application.xml found at org.jboss.deployment.EARDeployer.init(EARDeployer.java:133) at org.jboss.deployment.MainDeployer.init(MainDeployer.java:861) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:798) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:771) at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:260) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:190) at $Proxy6.deploy(Unknown Source) at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:334) at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:504) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:207) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:218) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:197)
I was OK w/ rebooting JBoss for a day but now it’s just taking up too much of my time when I want to see changes to my app…what can I do?
Thanks!
Riyad KallaMemberThere is nothing you can do, if you are using an exploded deployment you are not *suppose* to be redeploying over and over again to a running app server, you will run into this issue ever time as the app server will read-lock your JARs then MyEclipse cannot deploy. Anyway, an exploded deployment will automatically deploy changes as you save the files, so there shouldn’t be a need to keep manually redeploying.
zambizziMemberWell, that’s exactly my problem, it’s *not* automatically redeploying and it is an exploded archive…it doesn’t matter if I set it to “smart” deployment or jar’d deployment. Nothing happens automatically.
Riyad KallaMemberCan you double check that Window > Preferences > General > Workspace > “Build automatically” is checked? The deployment is hooked into the build cycle.
zambizziMemberIt’s definitely building automatically.
Riyad KallaMemberHmm ok let’s try this, recreate your exploded deployment, click the Browse button (from the deployment dialog after selecting your deployment) to open up an explorer window on your deployment. Go find a common jsp file like index.jsp, note the timestamp. Now wait about a minute and go back to MyEclipse and open/edit/save that index.jsp file, now go back to your browse window and check the timestamp, did it change?
-
AuthorPosts