On IRC, Robert suggested storing the last scanned revision ID. This may be more useful in debugging problems with the scanning.
Recording the last scan timestamp is probably a good idea still, since it might be more meaningful to users.
As far as the "last_scanned < last_mirrored" optimisation, it might be worth using revision IDs here and only scan if last_scanned_id != last_mirrored_id. This would require branch puller changes though.
On IRC, Robert suggested storing the last scanned revision ID. This may be more useful in debugging problems with the scanning.
Recording the last scan timestamp is probably a good idea still, since it might be more meaningful to users.
As far as the "last_scanned < last_mirrored" optimisation, it might be worth using revision IDs here and only scan if last_scanned_id != last_mirrored_id. This would require branch puller changes though.