Skip to content

Conversation

@julio-lopez
Copy link
Collaborator

No description provided.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds content-to-pack consistency checks during maintenance operations to verify that all referenced packs are present in storage. The feature is controlled by an environment variable and runs probabilistically.

  • Introduces a new content index verification function that checks consistency between content index entries and pack files
  • Replaces ReportRun calls with reportRunAndMaybeCheckContentIndex across maintenance tasks to enable optional consistency checking
  • Implements probabilistic execution based on the KOPIA_MAINTENANCE_CONTENT_VERIFY_PERCENTAGE environment variable

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
content_index_to_pack_check.go New file implementing content-to-pack consistency checking logic
maintenance_run.go Updates maintenance task functions to use the new consistency checking wrapper
index_compaction.go Updates index compaction task to use the new consistency checking wrapper

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@codecov
Copy link

codecov bot commented Sep 18, 2025

Codecov Report

❌ Patch coverage is 40.74074% with 32 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.43%. Comparing base (cb455c6) to head (bcb6070).
⚠️ Report is 665 commits behind head on master.

Files with missing lines Patch % Lines
repo/maintenance/content_index_to_pack_check.go 25.58% 32 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4832      +/-   ##
==========================================
+ Coverage   75.86%   76.43%   +0.56%     
==========================================
  Files         470      533      +63     
  Lines       37301    40591    +3290     
==========================================
+ Hits        28299    31025    +2726     
- Misses       7071     7526     +455     
- Partials     1931     2040     +109     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

@redgoat650 redgoat650 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just one question

Copy link
Collaborator

@Rohit-BM18 Rohit-BM18 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@julio-lopez julio-lopez force-pushed the poc/maintenanance-content-verify branch from 0fac4ca to bcb6070 Compare September 24, 2025 00:21
@julio-lopez julio-lopez marked this pull request as ready for review September 24, 2025 02:07
@julio-lopez julio-lopez merged commit 3f03531 into kopia:master Sep 24, 2025
25 checks passed
@julio-lopez julio-lopez deleted the poc/maintenanance-content-verify branch September 24, 2025 02:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants