Skip to content
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

add cleanup db command #588

Closed
wants to merge 3 commits into from
Closed

add cleanup db command #588

wants to merge 3 commits into from

Conversation

fho
Copy link
Collaborator

@fho fho commented Jun 20, 2024

Add a "cleanup db" command.
The commands removes all tasks runs that have been started before a
given timestamp.
When run it prints what it will do and gives the user 5sec to abort.
This can be skipped by passing the --force parameter.
It prints the number of deleted records.

--pretend can be passed to not do anything and only print the number of
records that would be deleted.

fho added 2 commits June 19, 2024 14:22
- truncate durations >=1 minute to 1 second precision,
- truncate durations >=1 second to 1 millisecond precision,
- limit precision to max. 1µs,
@fho fho self-assigned this Jun 20, 2024
@fho fho marked this pull request as ready for review June 21, 2024 09:01
@fho fho marked this pull request as draft June 21, 2024 09:08
Add a "cleanup db" command.
The commands removes all tasks runs that have been started before a
given timestamp.
When run it prints what it will do and gives the user 5sec to abort.
This can be skipped by passing the --force parameter.
It prints the number of deleted records.

--pretend can be passed to not do anything and only print the number of
records that would be deleted.
@fho fho changed the title add db cleanup command add cleanup db command Jun 21, 2024
@fho fho marked this pull request as ready for review June 21, 2024 09:38
@fho
Copy link
Collaborator Author

fho commented Jun 21, 2024

merged manually

@fho fho closed this Jun 21, 2024
@fho fho deleted the db_cleanup branch June 21, 2024 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant