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

SOLR-17495: Change CLI delete command to not delete configs by default. #2761

Merged
merged 11 commits into from
Nov 8, 2024

Conversation

epugh
Copy link
Contributor

@epugh epugh commented Oct 12, 2024

https://issues.apache.org/jira/browse/SOLR-17495

Description

See jira

Solution

Makes --delete-config a opt in flag that specifies the user wants to delete their config along with their collection.

This would be a 10x only change since we are changing the feature.

Tests

Bats

@github-actions github-actions bot added documentation Improvements or additions to documentation tests cat:cli labels Oct 12, 2024
@epugh
Copy link
Contributor Author

epugh commented Oct 12, 2024

@malliaridis

Copy link
Contributor

@malliaridis malliaridis left a comment

Choose a reason for hiding this comment

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

Thanks for the PR. I would like to notify somehow the user about the change of the default behavior by showing a message when using the delete tool, but I am not sure if there is a specific way to do so. This would only affect 9x.

We definitely have to mention that in the migration guide from 9 to 10.

A few more points to look into the bevario change:

  • solr-control-script-reference.adoc#799-800: the behavior described is outdated
  • solr/packaging/test/bats_helper.bash#74: Previously delete_all_collections delete configs as well if no longer used (old behavior)
  • solr/packaging/test/test_basic_auth.bats#60: we should probably delete the config explicitly here and check for its deletion
  • solr/solr-ref-guide/modules/getting-started/pages/tutorial-films.adoc#491: we could probably delete the config explicitily here as well
  • solr/solr-ref-guide/modules/getting-started/pages/tutorial-techproducts.adoc#484: we could probably delete the config explicitily here as well

solr/core/src/java/org/apache/solr/cli/DeleteTool.java Outdated Show resolved Hide resolved
@epugh
Copy link
Contributor Author

epugh commented Oct 14, 2024

Leaving "tutorial-films.adoc" and "tutorial-techproducts.adoc" alone, as they default configs like _default and we wouldn't want to delete it.

@epugh epugh requested a review from janhoy November 7, 2024 10:59
@epugh
Copy link
Contributor Author

epugh commented Nov 7, 2024

@janhoy would you mind weighing in ont this PR since it changes a default behavior?

Copy link
Contributor

@janhoy janhoy left a comment

Choose a reason for hiding this comment

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

I think it is A Good Thing™ to de-couple these by default. I tested a collection delete in Admin UI and it also only deletes the collection, not the configset.

For all breaking changes there should be an entry in ref-guide "Major changes" chapter...

@epugh epugh merged commit b8cbe41 into apache:main Nov 8, 2024
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cat:cli documentation Improvements or additions to documentation tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants