Christian:

On Tuesday, November 18, 2003 1:07 PM Christian G. Warden wrote:

> On Tue, Nov 18, 2003 at 12:46:30PM -0600, Gary Murphy wrote:
>> <snip>
>> For a more radical storage saving approach we could consider storing only
>> one copy of a message for all recipients within the database.  This is
the
>> approach Oracle uses for its email package.  My users are insisting on
this
>> so, I am already working to make it happen.  However, the change will
>> require a large number of the base db_ methods be changed, one or two new
>> recipient delivery db_ methods created, one table added but physmessage
can
>> be removed, and delivery code modified to store only one copy of the
message
>> in messages and messagblks.  Finally, dbmail-smtp needs to be called only
>> once with a list of all database recipients or a generic database-to
address
>> and recipients contained within the header, which will have to be parsed.

> If you're working on this, please allow multiple username/mailbox
> combinations, e.g.
> dbmail-smtp user1:/lists/somelist user2 user3:/spam user4:/INBOX

The new table contains message_idnr, mailbox_idnr + all message flags.  The
messages table no longer contains copies of these.  This allows one user to
store multiple copies of a message as long as she/he only stores one copy in
a mailbox.  It also allows multiple users to store copies in their
individual mailboxes.

> Even better might be to allow the same message to be delivered to
> different users by separate invocations of dbmail-smtp and only storing
> a single copy of the message body based on Message-ID, but separate
> versions of headers for each user allowing headers such as Envelope-To
> without exposing bcc'd recipients.

I had not thought about the Bcc: issue.  Sendmail, etc. should strip this
but if it does then I will have to accept one call per user to be inserted,
which will generate different headers but isn't optimal.  If it doesn't I
will strip the Bcc: out within dbmail-smtp, which I prefer.  However, beyond
not exposing blind-copy users, which I have no intention of doing, I do not
understand what would be gained by storing a separate header for each user.
Is a separate Message-ID and or Envelope-To really that important as long as
blind-copy users are not exposed?  The message can be easily identified by
one Message-ID and it's internal unique_id will always be the same no matter
who is on the recipients list.

> Even more ambitious would be to parse MIME and store only a single copy
> of unique MIME attachments so users who forward around 10MB files don't
> take up so much space.

Attachments are stored by dbmail as part of the message body within a
messageblk, so only one copy will ever be stored, if this approach works.
      ...... Gary .......

Reply via email to