-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement image builder database maintenance (HMS-4244) #1402
base: main
Are you sure you want to change the base?
Implement image builder database maintenance (HMS-4244) #1402
Conversation
8e097b5
to
12c937d
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅ |
12c937d
to
0e26d6e
Compare
6af80e6
to
dc5cafe
Compare
Note: failed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great. The only concern I have is why this is a separate image, but this could be app-sre requirement, no issues.
@lzap |
Refactoring this into a separate repo or somehow sharing code with composer was considered but discarded for less effort. |
will be used in more database tests like the image-builder-maintenance
918f709
to
255d1fd
Compare
image-builder-maintenance for now runs vacuum and cleans all composes older than 2 years (by default) to remove customer related data according to the retention policy As this is not really urgent, it's scheduled once a week on Tuesdays to avoid problems on weekends
the behavior of flushing seems to have changed between postgres 12 and the current (17) so we need a "CHECKPOINT" to assure for vacuum to be tested correctly
for now we'll skip this test as it's not really mission critical and should not stop us from delivering the maintenance job.
instead of implementing our selfs, this should be a more clean and feature rich solution
the test executable was called like the target program
255d1fd
to
808d4ec
Compare
also introduces a github action test for the container
808d4ec
to
e5de212
Compare
This implements the retention policy requested in https://issues.redhat.com/browse/HMS-4244
image-builder-maintenance for now runs vacuum
and cleans all composes older than 2 years (by default)
to remove customer related data according to the
retention policy
As this is not really urgent, it's scheduled once
a week on Tuesdays to avoid problems on weekends
…should be merged after #1398
Note: this implementation is almost a copy of https://github.com/osbuild/osbuild-composer/tree/main/cmd/osbuild-service-maintenance to stick to the same mechanism