Michael,

> Guess I have to break down and implement sql logging :-)

:-)

I had an intermediate version which used a separate table:

CREATE TABLE penpals (
  sid        integer NOT NULL, -- sender: maddr.id
  rid        integer NOT NULL, -- recipient: maddr.id
  send_time  integer NOT NULL, -- seconds since Unix epoch
  PRIMARY KEY (rid,sid),
  FOREIGN KEY (sid) REFERENCES maddr(id) ON DELETE RESTRICT,
  FOREIGN KEY (rid) REFERENCES maddr(id) ON DELETE RESTRICT
);

and used existing table maddr, but did not have to use msgs and msgrcpt.
The table would be smaller, but adds complexity for updating it,
involves an incompatible change to purging procedure, a need to add
another table, and complicated documentation, so in the end I removed it
in favour of simplicity and maintaining full compatibility without
upgrade steps.

> Sure beats the (non reliable way) I have been doing it
> (with message id matches on Reference: header!)

At sites with lots of traffic I would recommend to place
SQL logging to a PostgreSQL: the purging of outdated records
seems to be MUCH faster that in MySQL. Don't know why.

  Mark


_______________________________________________
AMaViS-user mailing list
AMaViS-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/

Reply via email to