Order orphans by path
It costs more cycles, but the SHA-1 they got implicitly ordered by is pseudo-random.
This commit is contained in:
parent
0530c5d95f
commit
b73e0b4622
3
main.go
3
main.go
@ -687,7 +687,8 @@ func getOrphans() (result []webOrphan, err error) {
|
|||||||
FROM orphan AS o
|
FROM orphan AS o
|
||||||
JOIN image AS i ON o.sha1 = i.sha1
|
JOIN image AS i ON o.sha1 = i.sha1
|
||||||
LEFT JOIN tag_assignment AS ta ON o.sha1 = ta.sha1
|
LEFT JOIN tag_assignment AS ta ON o.sha1 = ta.sha1
|
||||||
GROUP BY o.sha1`)
|
GROUP BY o.sha1
|
||||||
|
ORDER BY path`)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user