#1824 additional options to clean database
Merged by tkopecek. Opened by tkopecek.
tkopecek/koji issue1707  into  master

Download 1824.patch

Fixes: https://pagure.io/koji/issue/1707

As mentioned in the issue, would partitioning this old data to some archive tables make more sense than outright deletion?

Out of what's there, deleting old sessions data makes the most sense to me.

Yes, partitioning is ok for most usecases. I wanted to provide additional options, how to deal with old data. Especially in some test CI envs, where is no need for audit, deleting old data could prove useful. I've tried to be more verbose about potentially wrong tables with adding --force, but maybe we shouldn't provide this at all?

it looks possible to make the sql too long at the first run. maybe a temp table make more sense?

Metadata Update from @tkopecek:
- Pull-request tagged with: testing-ready

rebased onto 39a47d63c2dbb07d99b766d97e9a58630b2157f5

updated

:thumbsup:

rebased onto a0238cca51e98fb1666d649688f1df0e6178617c

rebased onto 4af1c19101c0ada8cc56a7f30d8f9a547c143e2f

Metadata Update from @jcupova:
- Pull-request tagged with: testing-done

rebased onto b09fd01677eaf38422db2805ba16254c7a3d0785

Commit 72044c1c fixes this pull-request

Pull-Request has been merged by tkopecek

Metadata