public static final SimpleDateFormat dateFormat = new SimpleDateFormat("EEE, d MMM yyyy HH:mm:ss Z");
public static final int numOutgoingThreads = 5;
+ private static final SqliteMailbox allmail =
+ (SqliteMailbox)FileBasedMailbox
+ .getFileBasedMailbox("/afs/megacz.com/mail/user/megacz/allmail", false);
+
public static final int GRAYLIST_MINWAIT = 1000 * 60 * 60; // one hour
public static final int GRAYLIST_MAXWAIT = 1000 * 60 * 60 * 24 * 5; // five days
public static void enqueue(Message m) throws IOException {
if (!m.envelopeTo.isLocal()) Outgoing.enqueue(m);
- else Target.root.accept(m);
+ else {
+ try {
+ allmail.accept(m);
+ } catch (Exception e) {
+ // FIXME incredibly gross hack
+ if (e.toString().indexOf("attempt to insert two messages with identical messageid")==-1)
+ Log.error(SMTP.class, e);
+ }
+ Target.root.accept(m);
+ }
}
public static class SMTPException extends MailException {