Commit 510f10c
scan: Log when the result of a mirror scan is commited to the database
So far, when a mirror is scanned, we have two logs: when it starts, and
when it ends:
```
2025/05/19 01:21:10.644 UTC [archive-4.kali.org] Requesting file list via rsync...
2025/05/19 01:22:42.670 UTC [archive-4.kali.org] Indexed 490848 files (490847 known), 3807 removed
```
We don't have a timestamp in the middle, to indicate that the scan is
finished, and we're about to commit the result to the database. Too bad,
as it's sometimes useful to know how long it took for the scan, and how
long it took for the commit.
And as we can see, when the source is scanned, we do have this
information:
```
2025/05/19 00:25:22.639 UTC [source] Scanning the filesystem...
2025/05/19 00:25:58.265 UTC [source] Indexing the files...
2025/05/19 00:26:02.360 UTC [source] Indexed 490848 files, 3807 removed
```
So this commit aligns the logs for mirror scan with the logs for source
scan: it adds this extra log before starting the commit operation.
Now the logs look like that:
```
2025/05/19 01:21:10.644 UTC [archive-4.kali.org] Requesting file list via rsync...
2025/05/19 01:22:37.927 UTC [archive-4.kali.org] Indexing the files...
2025/05/19 01:22:42.670 UTC [archive-4.kali.org] Indexed 490848 files (490847 known), 3807 removed
```1 parent 8065587 commit 510f10c
1 file changed
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
149 | 149 | | |
150 | 150 | | |
151 | 151 | | |
| 152 | + | |
| 153 | + | |
152 | 154 | | |
153 | 155 | | |
154 | 156 | | |
| |||
0 commit comments