Reset retransmission times when contact's mailbox props change

This commit is contained in:
Daniel Lublin
2022-04-04 12:00:29 +02:00
parent d5e17c8201
commit 68e57bda0d
2 changed files with 12 additions and 0 deletions

View File

@@ -158,6 +158,12 @@ class MailboxPropertyManagerImpl implements MailboxPropertyManager,
BdfList body = clientHelper.getMessageAsList(txn, m.getId());
MailboxPropertiesUpdate p = parseProperties(body);
txn.attach(new RemoteMailboxPropertiesUpdateEvent(c, p));
// Reset message retransmission timers for the contact. Avoiding
// messages getting stranded:
// - on our mailbox, if they now have a mailbox but didn't before
// - on the contact's old mailbox, if they removed their mailbox
// - on the contact's old mailbox, if they replaced their mailbox
db.resetUnackedMessagesToSend(txn, c);
} catch (FormatException e) {
throw new InvalidMessageException(e);
}