]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
director: Added more debug logging.
authorTimo Sirainen <tss@iki.fi>
Fri, 20 Sep 2013 07:00:48 +0000 (10:00 +0300)
committerTimo Sirainen <tss@iki.fi>
Fri, 20 Sep 2013 07:00:48 +0000 (10:00 +0300)
src/director/director-connection.c

index dc1bb10a4c9d7a24cee0d6a5efc7ca3c4f0ab10e..b52bcfe6b0bf52178ce289be8fb0998ee557b3a3 100644 (file)
@@ -1122,15 +1122,23 @@ director_connection_sync_host(struct director_connection *conn,
        } else {
                if (seq < host->last_sync_seq) {
                        /* stale SYNC event */
+                       dir_debug("Ignore stale SYNC event for %s (seq %u < %u)",
+                                 host->name, seq, host->last_sync_seq);
                        return FALSE;
                } else if (host->last_sync_seq != seq ||
                           timestamp > host->last_sync_timestamp) {
                        host->last_sync_seq = seq;
                        host->last_sync_timestamp = timestamp;
                        host->last_sync_seq_counter = 1;
+                       dir_debug("Update SYNC for %s (seq=%u, timestamp=%u)",
+                                 host->name, seq, timestamp);
                } else if (++host->last_sync_seq_counter >
                           DIRECTOR_MAX_SYNC_SEQ_DUPLICATES) {
                        /* we've received this too many times already */
+                       dir_debug("Ignore duplicate #%u SYNC event for %s "
+                                 "(seq=%u, timestamp %u <= %u)",
+                                 host->name, host->last_sync_seq_counter, seq,
+                                 timestamp, host->last_sync_timestamp);
                        return FALSE;
                }