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 a DB function to delete all selectors for a profile #3942

Merged
merged 2 commits into from
Jul 19, 2024

Conversation

jhrozek
Copy link
Contributor

@jhrozek jhrozek commented Jul 19, 2024

Summary

We'll do a dumb but easy way of updating selectors - we'll drop all
current for the profile being updated and re-add them.

Relates: #3723

Change Type

  • Bug fix (resolves an issue without affecting existing features)
  • Feature (adds new functionality without breaking changes)
  • Breaking change (may impact existing functionalities or require documentation updates)
  • Documentation (updates or additions to documentation)
  • Refactoring or test improvements (no bug fixes or new functionality)

Testing

there is a test + I cherry-picked the patch out of a larger branch

Review Checklist:

  • Reviewed my own code for quality and clarity.
  • Added comments to complex or tricky code sections.
  • Updated any affected documentation.
  • Included tests that validate the fix or feature.
  • Checked that related changes are merged.

@jhrozek jhrozek requested a review from a team as a code owner July 19, 2024 13:52
We'll do a dumb but easy way of updating selectors - we'll drop all
current for the profile being updated and re-add them.

Relates: mindersec#3723
@jhrozek jhrozek force-pushed the selectors_delete_by_profile branch from 1f35ab0 to 5a5cb54 Compare July 19, 2024 14:01
@coveralls
Copy link

coveralls commented Jul 19, 2024

Coverage Status

coverage: 54.402% (-0.005%) from 54.407%
when pulling b0c0f21 on jhrozek:selectors_delete_by_profile
into dccc11a on stacklok:main.

Copy link
Contributor

@dmjb dmjb left a comment

Choose a reason for hiding this comment

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

Assuming that the number of selectors is generally small, and that the selectors themselves are small - I think this is a reasonable approach to updates.

@jhrozek jhrozek merged commit b3b3256 into mindersec:main Jul 19, 2024
21 checks passed
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