Posted: January 02, 2014 14:44 by MALICE
I have recently taken over a couple of projects from a colleague and my first idea was to clean up some of the libraries he had in the project (want to switch to Maven, but need to figure out what I really need first).
I have 2 projects, both of which had java-mail in the classpath, although only 1 needs it (as far as I can tell). When I was done removing all unnecessary libs, both applications seemed to work fine when deployed separately. However, they should also work when deployed on the same server...
This is were the problem occurs... The project that needs (and has) java-mail, gives me the following exception:
javax.activation.UnsupportedDataTypeException: no object DCH for MIME type multipart/mixed;
Like I said, it only does this when the other project is also deployed.
After a couple of hours of playing around, I have figured out that I can remove this exception (and have mail working again) when I add the old 'mailapi' back into the second project.
Now, the 'mailapi' isn't that big, so I could include it, but I want to know why it is necessary to put it in there at all!?
Since I am working with web-apps (on Tomcat), I thought that the libraries that are included in my WAR are not shared between applications.
Can someone shed some light on this problem and maybe point me in the right direction to remove the 'mailapi' from the second project?
- JDK 1.6.0_38
- Tomcat 7.0.42
- mail.jar some old v.1.4, but it happens with the latest version as well