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

Handle wildcard parameter in Schema deletion API #446

Merged
merged 7 commits into from
Oct 11, 2024

Conversation

ThomasCAI-mlv
Copy link
Collaborator

No description provided.

@ThomasCAI-mlv ThomasCAI-mlv added the feature This issue adds a new feature label Sep 25, 2024
@ThomasCAI-mlv ThomasCAI-mlv self-assigned this Sep 25, 2024
@loicgreffier
Copy link
Collaborator

@ThomasCAI-mlv Linking #447. Note that notFound is thrown when version does not match among all the schemas

@ThomasCAI-mlv ThomasCAI-mlv marked this pull request as ready for review September 30, 2024 14:59
@ThomasCAI-mlv
Copy link
Collaborator Author

I adopted your errorHandling structure for "notFound" and "dryRun" cases.

As discussed together in case of deletion of version:

  1. I removed the ownership checker, as we don't want to restrict the usage of wildcard by forcing users to type the namespace prefix. The findByWildcard already filters the namespace's resources.

  2. We prefer anyMatch over allMatch to be homogeneous with other DELETE endpoint:

  • Deleting multiple connect clusters including at least one with connectors will lead to "ResourceValidationError"
  • Deleting multiple namespaces including at least one with resources inside will lead to "ResourceValidationError"
    So we can also implement the schema version deletion and throw "notFound" if at least one version doesn't exist.

Copy link

sonarqubecloud bot commented Oct 3, 2024

Copy link
Collaborator

@loicgreffier loicgreffier left a comment

Choose a reason for hiding this comment

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

LGTM

@loicgreffier loicgreffier merged commit 18ff01f into master Oct 11, 2024
3 checks passed
@loicgreffier loicgreffier deleted the feat/delete-schema-wildcard branch October 11, 2024 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature This issue adds a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants