Implement Decaying Runs in CodeChecker

オープン
#4,367 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 8 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
15/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
python

調査の方向性

The issue names no specific files or tests. Start from the existing storage command and the server's run-deletion path, then look at how run records are stored in the database. Done would mean a lifetime can be set at storage time, expired runs are removed by a background job, and the lifetime is visible in the CLI and web UI. Agree the design with maintainers first, since the work spans schema, server, CLI and UI.

索引モデルが issue の本文から書いたものです。

説明

CLI :computer: discussion :bulb: documentation :book: enhancement :star2: new feature :+1: server :desktop_computer: test :ballot_box_with_check: web :earth_africa:

Is your feature request related to a problem? Please describe.

There is a problem with CodeChecker runs accumulating and consuming excessive space on the server. For example, when using a Jenkins job to analyze a set of OpenSource projects, every build creates a new run in the CodeChecker server. These runs are not automatically cleaned up, leading to server storage issues over time.

Describe the solution you would like

Implement a "decaying runs" feature in CodeChecker with the following characteristics:

  1. Allow users to specify a lifetime for runs during the storage phase.
  2. Implement a backend mechanism that periodically cleans up runs older than their specified lifetime.
  3. Maintain backward compatibility by keeping runs indefinitely by default.
  4. Provide ways to view and modify the remaining time until deletion for runs in both the CLI and CodeChecker web UI.

Describe alternatives you have considered

  • Manual deletion of old runs: This requires constant monitoring and manual intervention, which is not scalable.
  • Fixed deletion schedule: This doesn't allow for flexibility in retention times for different types of runs.

Additional context

This feature would greatly improve the management of storage resources for CodeChecker servers, especially in CI/CD environments where new runs are frequently created.

Implementation details to consider:
  • Add a new parameter to the storage command to specify run lifetime.
  • Implement a background job in the server to check and delete expired runs.
  • Extend the database schema to include lifetime and expiration information for runs.
  • Update the CLI and web UI to display and allow modification of run lifetimes.
  • Ensure proper documentation of the new feature in the CodeChecker documentation.
  • Make sure to test the backend, the interaction with the web app and the CLI as well.
主要言語
Python
スター
2.6k
フォーク
494
平均マージ
9日 2時間
マージ済み PR(30日)
23

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

Ericsson/codechecker のほかの issue

Ericsson/codechecker の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。