Bug 35982

Summary: Deleting Mail Session Causes Error 500
Product: Tomcat 5 Reporter: Seth Ladd <seth>
Component: Webapps:AdministrationAssignee: Tomcat Developers Mailing List <dev>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P2    
Version: 5.5.9   
Target Milestone: ---   
Hardware: Other   
OS: other   

Description Seth Ladd 2005-08-02 21:11:17 UTC
When trying to delete a mail session created by the admin webapp, an error 500
generates.

It's easy to reproduce.  Simply add a mail session, then attempt to remove it. 
It seems to happen whether or not I commit the changes.

-------------
HTTP Status 500 - Error invoking operation removeResource

type Status report

message Error invoking operation removeResource

description The server encountered an internal error (Error invoking operation
removeResource) that prevented it from fulfilling this request.
Apache Tomcat/5.5.9
-------------

The log contains this message:

Aug 2, 2005 9:09:27 AM org.apache.catalina.core.ApplicationContext log
SEVERE: action: Error invoking operation removeResource
javax.management.MalformedObjectNameException: Unterminated key property part
	at javax.management.ObjectName.construct(ObjectName.java:465)
	at javax.management.ObjectName.<init>(ObjectName.java:1304)
	at
org.apache.webapp.admin.resources.DeleteMailSessionsAction.execute(DeleteMailSessionsAction.java:135)
	at
org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:419)
	at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)
	at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1192)
	at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:430)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at
org.apache.webapp.admin.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:123)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
	at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:482)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
	at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
	at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
	at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
	at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
	at java.lang.Thread.run(Thread.java:595)
Comment 1 Seth Ladd 2005-08-02 21:12:43 UTC
FYI, our config (generated by the admin webapp) looks like this:

    <Resource
      name="ehawaii"
      type="javax.mail.Session"
      mail.smtp.host="mail.ehawaii.gov"/>
Comment 2 Yoav Shapira 2005-11-11 03:29:31 UTC
I've fixed mailSessions.jspf in the admin webapp.  Thanks for reporting this.