geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim McConnell (JIRA)" <j...@apache.org>
Subject [jira] Commented: (GERONIMODEVTOOLS-575) GEP errors that are logged to the Eclipse error log are not always seen by end-user
Date Fri, 05 Jun 2009 16:10:07 GMT

    [ https://issues.apache.org/jira/browse/GERONIMODEVTOOLS-575?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12716658#action_12716658
] 

Tim McConnell commented on GERONIMODEVTOOLS-575:
------------------------------------------------

After looking at this problem more thoroughly I think I finally see what's going on. Ideally
as a best practice the GEP should strive to convey error and/or exception messages (to the
end user) in a consistent manner when interactions with the Geronimo server are involved.
Unfortunately, this is not the case as there seems to be multiples paths in the GEP that entail
interactions with the server that do not handle exceptions in a consistent, well-behaved manner.


A "relatively" good implementation of a usage scenario is when artifacts get deployed/undeployed
to the server. The GEP in most cases throws CoreExceptions (with nested exceptions and statuses)
that results in a "Problem Occurred" dialog with detailed information about the problem/exception.
One nice aspect of this approach is that it is fairly standard in Eclipse and is the same
approach used by WTP. Although this is the best example in the GEP, even this implementation
is far from perfect; there are at least three scenarios that are not handled correctly. One
is the case where WAR file can be deployed to the server that results in deployment errors
that are not conveyed to the end-user -- they are only written to the Eclipse Error log file.
The other case is the GERONIMODEVTOOLS-575 JIRA  just opened where a WAR file without a geroniom-web.xml
not only doesn't deploy, it doesn't convey anything to the end-user (not good), nor does it
write anything to the Eclipse Error log file. The third is the case where a Target Module
ID cannot be found on the server (i.e., TargetModuleIdNotFoundException) and is essentially
ignored by the GEP (again not good). 

Two other scenarios that involve interactions with the Geronimo server seem to be inconsistently
implemented. Errors starting and/or stopping the server don't do much other than log exceptions
to the Eclipse error log and depends upon WTP to throw the CoreException. But these CoreExceptions
are too generic to be of much value to the end-user. This can be seen when we try to start
the server with incorrect security credentials. The CoreException just conveys that the server
failed to start, which is all that WTP about knows. The GEP knows the root cause but only
writes it to Eclipse Error log, which is not normally visible to the end-user. Similarly,
errors connecting and/or disconnecting to/from the server are inconsistently handled which
makes diagnosis somewhat confusing or problematic for the end-user. 

My recommendation is that we refactor the code that interacts with the Geronimo server to
consistently throw CoreExceptions (with nested Exceptions and MultiStatus objects) and open
Error Dialogs when anything needs to be conveyed to the end-user. As noted above we do some
of this already, but not well-enough. Of the three typical usage scenarios I've mentioned
(connecting/disconnecting, starting/stopping, deploying/undeploying) I would think that starting/stopping
the server would be the easiest and most straightforward. This is just a guess at this point
though. Once that is accomplished I think that doing the same for the connecting/disconnecting
scenarios would be fairly easy, and hopefully we'd learn enough to then plug the existing
holes in the deploying/undeploying scenarios. Then finally as a last resort, if there are
cases where it is just impossible to throw a CoreExcpetion (and display an Error Dialog) to
convey information to the end-user we can then exercise the new code that I just recently
added to the GEP to display the Eclipse Error log. 

> GEP errors that are logged to the Eclipse error log are not always seen by end-user
> -----------------------------------------------------------------------------------
>
>                 Key: GERONIMODEVTOOLS-575
>                 URL: https://issues.apache.org/jira/browse/GERONIMODEVTOOLS-575
>             Project: Geronimo-Devtools
>          Issue Type: Bug
>          Components: eclipse-plugin
>    Affects Versions: 2.2.0, 2.1.4
>            Reporter: Tim McConnell
>            Assignee: Tim McConnell
>
> For example, when deploying an erroneous war file to the Geronimo server will result
in the following to the Eclispe.log that the end-user may not likely see.....
> !ENTRY org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE Distribution of module failed.  See log for details.
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE Unable to resolve resource reference 'jdbc/users' (Could not auto-map to resource.
 Try adding a resource-ref mapping to your Geronimo deployment plan.
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE Search conducted in current module and dependencies:
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/tomcat6/2.1.4/car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [CLASSES: org.apache.geronimo.configs/openejb//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/j2ee-corba-yoko//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/axis//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/axis2//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/openjpa//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE )
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE org.apache.geronimo.common.DeploymentException: Unable to resolve resource reference
'jdbc/users' (Could not auto-map to resource.  Try adding a resource-ref mapping to your Geronimo
deployment plan.
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE Search conducted in current module and dependencies:
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/tomcat6/2.1.4/car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [CLASSES: org.apache.geronimo.configs/openejb//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/j2ee-corba-yoko//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/axis//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/axis2//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE [ALL: org.apache.geronimo.configs/openjpa//car]
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE )
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.connector.deployment.ResourceRefBuilder.buildNaming(ResourceRefBuilder.java:216)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.j2ee.deployment.NamingBuilderCollection.buildNaming(NamingBuilderCollection.java:53)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.web25.deployment.AbstractWebModuleBuilder.configureBasicWebModuleAttributes(AbstractWebModuleBuilder.java:842)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.tomcat.deployment.TomcatModuleBuilder.addGBeans(TomcatModuleBuilder.java:347)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.j2ee.deployment.SwitchingModuleBuilder.addGBeans(SwitchingModuleBuilder.java:165)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:647)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:255)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:134)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at java.lang.reflect.Method.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:124)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:867)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:239)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.kernel.KernelGBean.invoke(KernelGBean.java:342)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at java.lang.reflect.Method.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:124)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:867)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:239)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at org.apache.geronimo.system.jmx.MBeanGBeanBridge.invoke(MBeanGBeanBridge.java:172)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at com.sun.jmx.mbeanserver.DynamicMetaDataImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at javax.management.remote.rmi.RMIConnectionImpl.doOperation(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at javax.management.remote.rmi.RMIConnectionImpl.access$100(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(Unknown
Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at java.security.AccessController.doPrivileged(Native Method)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(Unknown
Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at javax.management.remote.rmi.RMIConnectionImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.GeneratedMethodAccessor111.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at java.lang.reflect.Method.invoke(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.rmi.transport.Transport$1.run(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at java.security.AccessController.doPrivileged(Native Method)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.rmi.transport.Transport.serviceCall(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source)
> !SUBENTRY 1 org.apache.geronimo.st.core 4 0 2009-05-31 15:09:17.859
> !MESSAGE 	at java.lang.Thread.run(Unknown Source)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message