Help undeploying an incorrectly deployed application

Hi,

I deployed a J2EE application to my Application Server PE 8.2 from Net Beans IDE.

Even tough all seemed to be ok, after viewing the server log I found out that the deployment didn't complete successfully because of a timeout error.

Since then, after loggin into the Admin Console, I get the following exception:

A "com.sun.enterprise.tools.guiframework.exception.FrameworkError" was caught. The message from the exception: "Unable to get View for ViewDescriptor 'enterpriseApplications'"

The root cause is

"com.sun.enterprise.admin.common.exception.MBeanConfigException: Component not registered"

error when I use Admin Console .

I'd need some help on how to undeploy the failing application, as I've been unable to do it using either asadmin or deploytool (I get the error "Component is not registered").

Thanks in advance

[898 byte] By [Epicuro] at [2007-11-26 8:33:53]
# 1

This is a great use case.

I will be interested in more details (c.f. end of this message).

This particular error shows up mainly when there is a corrupt memory

of configuration context and failed deployment recovery process

for app server in memory. Basically, even though you

think that you've deployed the application, app server thinks that it is not

there in its configuration. Here are a few things to check:

- List the applications. Use either admin console or asadmin list-components and make sure that your application is listed there.

- If the list operation does not return your application, you can rest

assured that deployment of your application was successfully rolled back

.

- Fix the application and deploy using asadmin deploy command.

Hope this helps.

It is worthwhile to find out why this deployment failed and then implicit

rollback also failed. What did the server.log say about application?

Please let me know ...

Regards,

Kedar

kedarmhaswade at 2007-7-6 22:00:19 > top of Java-index,Application & Integration Servers,Application Servers...
# 2

Kedar, I managed to solve the problem through a plain asadmin undeploy. Once undeployed the application, all seems to work well.

However, I'm still interested in knowing what could cause the problem.

This is what the server log says about the deployment of the application(j2eesampleapp is the application I tried to deploy - it consists of an entity bean and a EJB web service):

[#|2006-07-06T13:44:14.370+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.admin|_ThreadID=12;|ADM1041:Sent the event to instance:[ResourceDeployEvent -- reference-added jdbc/jdbc/mysql]|#]

[#|2006-07-06T13:44:47.411+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.core|_ThreadID=12;|CORE5004: Resource Deployed: [jdbc:jdbc/mysql].|#]

[#|2006-07-06T13:45:20.302+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.deployment|_ThreadID=16;|DPL5109: EJBC - START of EJBC for [j2eesampleapp]|#]

[#|2006-07-06T13:47:50.184+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.deployment|_ThreadID=16;|Processing beans ...|#]

[#|2006-07-06T13:52:36.607+0200|SEVERE|sun-appserver-pe8.2|javax.enterprise.system.container.web|_ThreadID=15;|StandardWrapperValve[RemoteJmxConnectorServlet]: Servlet.service() for servlet RemoteJmxConnectorServlet threw exception

java.io.EOFException

at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2232)

at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:2698)

at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:750)

at java.io.ObjectInputStream.<init>(ObjectInputStream.java:268)

at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.readRequestMessage(RemoteJmxConnectorServlet.java:98)

at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:68)

at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:94)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:767)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:860)

at sun.reflect.GeneratedMethodAccessor104.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)

at java.security.AccessController.doPrivileged(Native Method)

at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)

at org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)

at org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:257)

at org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)

at org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)

at java.security.AccessController.doPrivileged(Native Method)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:263)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:225)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:173)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:132)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)

at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:933)

at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:189)

at com.sun.enterprise.web.connector.grizzly.ProcessorTask.doProcess(ProcessorTask.java:604)

at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:475)

at com.sun.enterprise.web.connector.grizzly.ReadTask.executeProcessorTask(ReadTask.java:371)

at com.sun.enterprise.web.connector.grizzly.ReadTask.doTask(ReadTask.java:264)

at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:281)

at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:83)

|#]

[#|2006-07-06T13:56:10.528+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.deployment|_ThreadID=16;|DPL5306:EJB Web Service Endpoint [FachadeProveedor] listening at address [http://gestor-prueba.ingenieria.eolica.corp.gamesa.es:8080/webservice/FachadeProveedor]|#]

[#|2006-07-06T13:59:35.556+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.deployment|_ThreadID=16;|DPL5110: EJBC - END of EJBC for [j2eesampleapp]|#]

[#|2006-07-06T13:59:53.774+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.deployment|_ThreadID=16;|Total Deployment Time: 891340 msec, Total EJB Compiler Module Time: 855274 msec, Portion spent EJB Compiling: 95%

Breakdown of EJBC Module Time: Total Time for EJBC: 855274 msec, CMP Generation: 12229 msec (1%), Java Compilation: 133827 msec (15%), RMI Compilation: 0 msec (0%), JAX-RPC Generation: 480754 msec (56%),

|#]

[#|2006-07-06T14:00:03.919+0200|INFO|sun-appserver-pe8.2|javax.enterprise.system.tools.deployment|_ThreadID=16;|deployed with moduleid = j2eesampleapp|#]

[#|2006-07-06T14:07:57.202+0200|WARNING|sun-appserver-pe8.2|javax.enterprise.system.tools.admin|_ThreadID=14;|Exception in getStatus:Component not registered|#]

This is the error message I got when I run asadmin list-components

Operation 'getAllUserDeployedComponents' failed in 'applications' Config Mbean.

Target exception message: javax.management.InstanceAlreadyExistsException: com.sun.appserv:type=j2ee-application,name=j2eesampleapp,category=config

CLI137 Command list-components failed.

This is the error message I got when I used Admin Console to force a redeployment of the application

Application j2eesampleapp is already deployed on other targets.

Please use create-application-ref command to create reference to the specified target; requested operation cannot be completed

Thanks again for your valuable help

Epicuro at 2007-7-6 22:00:19 > top of Java-index,Application & Integration Servers,Application Servers...