Details
-
Type:
Bug Fix
-
Status:
Closed
-
Priority:
Critical
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 1.0
-
Component/s: Development
-
Labels:None
-
Similar issues:
KULRICE-3907Remove geronimo java mail jar from Rice KULRICE-8472Include information on CXF upgrade in release notes KULRICE-6236EN-548 Document Client-side Dependencies KULRICE-10638 Rice is pulling in multiple versions of the commons-chain artifact KULRICE-7907Exclude jsp-api from jstl-impl dependency KULRICE-13810 CI report for jars which are not current KULRICE-4971 DataDictionaryIndex currently indexes based on "simple" class name which can result in silent conflicts in DD classes KULRICE-5188Need to remove ImmutableListAdapter and ImmutableCollectionAdapter from our service definitions and come up with a better solution because it is producing undesirable XML KULRICE-5109Upgrade Apache CXF from 2.3.8 to 2.7.0 and wss4j from 1.5.x to 1.6.7 KULRICE-4457rice 1.0.3 fails to compile with java 5 b/c of missing dependency
Description
See the email pasted below from the Rice user list. The solution that I think we need to do is just manually exclude the geronimo mail jar from our CXF dependency in our POM file.
>>>>>>>
We're using the rice-release-0-9-4-br code base, planning on having a
central rice instance for KIM but, at least for now, embedding KEW in
our application (embedded, not bundled, if I've kept the terms straight)
It was recently brought to my attention that the email we generate from
our application is now missing the "To:", "From:", and "Subject:" lines,
in our development version where we're adding the rice code.
I've tracked this problem down to the "Geronimo" javamail jar that we
get out of the rice build.
From what I've been able to glean so far, the rice pom.xml references
Apache CXF which, in turn, references Apache Geronimo. The ultimate
result is that several "geronimo-*.jar" files end up in our deployed
app, and specifically geronimo-javamail_1.4_spec-1.3.jar – which
conflicts with Sun's mail.jar
If I remove the geronimo javamail jar our email starts working again.
Since this is an implementation of JavaMail I thought I could remove the
standard mail.jar and use what Rice gave me, but when I tried that the
SMTP send fails because there's no transport class for it:
org.apache.geronimo.javamail.transport.smtp is not in any of the
geronimo-* jar files.
It seems there's a javamail-providers jar file I've seen mentioned while
trying to track this down, but it may be part of the CXF or Geronimo
Maven build and not out there available for a simple download; anyway, I
haven't found one.
Also, an old email thread from the cxf-user list
http://www.mail-archive.com/cxf-user@incubator.apache.org/msg02144.html
implies it is supposed to be safe to drop the geronimo jar in favor of
the standard sun mail.jar but there was once a dependency problem that's
likely fixed now.
Are the geronimo jars – the CXF and/or Geronimo classes – still used
in rice, or might they be cruft from earlier versions? That is, is it
safe to just delete the jar file that's giving me a problem?
If they're still used, is it safe at this point to delete that jar
anyway and rely on mail.jar for whatever dependencies rice has?
If it's not, that seems to imply that I have to switch to the Apache
Geronimo implementation for JavaMail, and in that case the rice pom
should also include the transport providers in some way, otherwise rice
will break existing email implementations.
Added:
<dependency>
{cxf.version}<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-jaxws</artifactId>
<version>$
</version>
<exclusions>
<exclusion><!-- avoids conflict with javamail -->
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-javamail_1.4_spec</artifactId>
</exclusion>
</exclusions>
</dependency>
to parent POM. Then packaged and checked if standalone included exclusion. It did not, so I'm marking resolved.