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

feat(scrubber): post scan_metadata results to storage controller #8502

Conversation

yliang412
Copy link
Contributor

@yliang412 yliang412 commented Jul 25, 2024

Part of #8128, followup to #8480. closes #8421.

Enable scrubber to optionally post metadata scan health results to storage controller.

Checklist before requesting a review

  • I have performed a self-review of my code.
  • If it is a core feature, I have added thorough tests.
  • Do we need to implement analytics? if so did you add the relevant metrics to the dashboard?
  • If this PR requires public announcement, mark it with /release-notes label and add several sentences in this section.

Checklist before merging

  • Do not forget to reformat commit message to not include the above checklist

@yliang412 yliang412 changed the title [WIP] feat(scrubber): post results to storage controller [WIP] feat(scrubber): post scan_metadata results to storage controller Jul 25, 2024
@yliang412 yliang412 added the c/storage/scrubber Component: s3_scrubber label Jul 25, 2024
@yliang412 yliang412 self-assigned this Jul 25, 2024
@yliang412 yliang412 linked an issue Jul 25, 2024 that may be closed by this pull request
yliang412 and others added 2 commits July 25, 2024 00:53
Signed-off-by: Yuchen Liang <[email protected]>
…uchen/post-scrub-results-to-storage-controller-part-2-use-scrubber
Copy link

github-actions bot commented Jul 25, 2024

3150 tests run: 3029 passed, 0 failed, 121 skipped (full report)


Code coverage* (full report)

  • functions: 32.5% (7022 of 21597 functions)
  • lines: 49.9% (55884 of 111992 lines)

* collected from Rust tests only


The comment gets automatically updated with the latest test results
2d170fa at 2024-07-30T14:32:25.236Z :recycle:

@yliang412 yliang412 changed the title [WIP] feat(scrubber): post scan_metadata results to storage controller feat(scrubber): post scan_metadata results to storage controller Jul 25, 2024
@yliang412 yliang412 marked this pull request as ready for review July 25, 2024 17:05
@yliang412 yliang412 requested a review from a team as a code owner July 25, 2024 17:05
@yliang412 yliang412 requested review from arssher and VladLazar and removed request for a team and arssher July 25, 2024 17:05
Copy link
Contributor

@VladLazar VladLazar left a comment

Choose a reason for hiding this comment

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

lgtm

storage_scrubber/src/main.rs Show resolved Hide resolved
yliang412 added a commit that referenced this pull request Jul 30, 2024
Part of #8128, followed by #8502.

## Problem

Currently we lack mechanism to alert unhealthy `scan_metadata` status if
we start running this scrubber command as part of a cronjob. With the
storage controller client introduced to storage scrubber in #8196, it is
viable to set up alert by storing health status in the storage
controller database.

We intentionally do not store the full output to the database as the
json blobs potentially makes the table really huge. Instead, only a
health status and a timestamp recording the last time metadata health
status is posted on a tenant shard.

Signed-off-by: Yuchen Liang <[email protected]>
Base automatically changed from yuchen/post-scrub-results-to-storage-controller to main July 30, 2024 13:32
@yliang412 yliang412 enabled auto-merge (squash) July 30, 2024 13:38
@yliang412 yliang412 disabled auto-merge July 30, 2024 14:26
@yliang412 yliang412 enabled auto-merge (squash) July 30, 2024 14:47
@yliang412 yliang412 merged commit 85bef9f into main Jul 30, 2024
66 checks passed
@yliang412 yliang412 deleted the yuchen/post-scrub-results-to-storage-controller-part-2-use-scrubber branch July 30, 2024 15:07
arpad-m pushed a commit that referenced this pull request Aug 5, 2024
Part of #8128, followed by #8502.

## Problem

Currently we lack mechanism to alert unhealthy `scan_metadata` status if
we start running this scrubber command as part of a cronjob. With the
storage controller client introduced to storage scrubber in #8196, it is
viable to set up alert by storing health status in the storage
controller database.

We intentionally do not store the full output to the database as the
json blobs potentially makes the table really huge. Instead, only a
health status and a timestamp recording the last time metadata health
status is posted on a tenant shard.

Signed-off-by: Yuchen Liang <[email protected]>
arpad-m pushed a commit that referenced this pull request Aug 5, 2024
…8502)

Part of #8128, followup to #8480. closes #8421. 

Enable scrubber to optionally post metadata scan health results to
storage controller.

Signed-off-by: Yuchen Liang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c/storage/scrubber Component: s3_scrubber
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Store scrubber scan_metadata health status in storage controller
2 participants