james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Noel J. Bergman" <n...@devtech.com>
Subject RE: ID-mail
Date Fri, 07 Mar 2003 02:03:26 GMT
> In fact I must keep the same ID to make tri on the mails incoming on

We understand the issue, and the problems that occur when Message-ID is
changed because you have added a header to a MimeMessage.  This is not
something that James does; it is part of JavaMail.  I am cc'ing the
JavaMail-Interest list on this reply.    Sun may have some suggestion(s).

RFC 2822, section 3.6.4, states:

   Note: There are many instances when messages are "changed", but those
   changes do not constitute a new instantiation of that message, and
   therefore the message would not get a new message identifier.  For
   example, when messages are introduced into the transport system, they
   are often prepended with additional header fields such as trace
   fields (described in section 3.6.7) and resent fields (described in
   section 3.6.6).  The addition of such header fields does not change
   the identity of the message and therefore the original "Message-ID:"
   field is retained.  In all cases, it is the meaning that the sender
   of the message wishes to convey (i.e., whether this is the same
   message or a different message) that determines whether or not the
   "Message-ID:" field changes, not any particular syntactic difference
   that appears (or does not appear) in the message.

JavaMail changes the Message-ID header whenever you call
MimeMessage.saveChanges().  This occurs in MimeMessage.updateHeaders().
Rather than require applications to subclass MimeMessage to override this
behavior, perhaps a future version of JavaMail could facilitate keeping the
existing  Message-ID except when the application explicitly wants a new one.

In the meantime, changing this behavior under JavaMail v1.3 requires
subclassing the MimeMessage class.  We plan to do that in James v3 for the
local stores.  It could be done in James v2 as well, with an
org.apache.[mailet | james].MimeMessage class that would be used instead of
MimeMessage throughout the code.  We'd have to override updateHeaders.

	--- Noel

To unsubscribe, e-mail: james-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: james-dev-help@jakarta.apache.org

View raw message