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

Removing folders verbiage from CONVENTIONS.md #186

Merged
merged 1 commit into from
Dec 9, 2022

Conversation

mnkugler
Copy link
Contributor

@mnkugler mnkugler commented Dec 1, 2022

Signed-off-by: mnkugler [email protected]

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@mnkugler mnkugler requested a review from a team December 1, 2022 18:26
@dblock
Copy link
Member

dblock commented Dec 6, 2022

I saw a few PRs from different branches.

You can force push an amended change to GitHub with git push origin branch-name -f, it will overwrite the change.

@saratvemulapalli
Copy link
Member

@mnkugler @dblock is there some background history I am missing? (Why are we removing the recommendations?)

@mnkugler
Copy link
Contributor Author

mnkugler commented Dec 6, 2022

@mnkugler @dblock is there some background history I am missing? (Why are we removing the recommendations?)

@saratvemulapalli We are only removing the folders verbiage because the recommendations are outdated now that we're shifting to one plugin per repo as per opensearch-project/opensearch-build#2188.

@saratvemulapalli
Copy link
Member

@mnkugler @dblock is there some background history I am missing? (Why are we removing the recommendations?)

@saratvemulapalli We are only removing the folders verbiage because the recommendations are outdated now that we're shifting to one plugin per repo as per opensearch-project/opensearch-build#2188.

@mnkugler the convention listed here[1] is to help plugin developers name the plugin to reflect how it shows up after they are installed but not how they are structured within the code repository. I hope that makes sense.
For example: opensearch-knn shows up as plugins/opensearch-knn.

:~/opensearch-2.2.1$ ls -la plugins/
total 72
drwxr-xr-x 18 ubuntu ubuntu 4096 Sep  7 23:11 .
drwxr-xr-x 11 ubuntu ubuntu 4096 Sep  7 23:10 ..
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-alerting
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-anomaly-detection
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-asynchronous-search
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-cross-cluster-replication
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-geospatial
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-index-management
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-job-scheduler
drwxr-xr-x  3 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-knn
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-ml
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-notifications
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-notifications-core
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-observability
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-performance-analyzer
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-reports-scheduler
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-sql
drwxr-xr-x  2 ubuntu ubuntu 4096 Sep  7 23:06 repository-s3

[1] https://github.com/opensearch-project/opensearch-plugins/blob/main/CONVENTIONS.md#folders

@mnkugler
Copy link
Contributor Author

mnkugler commented Dec 6, 2022

@mnkugler @dblock is there some background history I am missing? (Why are we removing the recommendations?)

@saratvemulapalli We are only removing the folders verbiage because the recommendations are outdated now that we're shifting to one plugin per repo as per opensearch-project/opensearch-build#2188.

@mnkugler the convention listed here[1] is to help plugin developers name the plugin to reflect how it shows up after they are installed but not how they are structured within the code repository. I hope that makes sense. For example: opensearch-knn shows up as plugins/opensearch-knn.

:~/opensearch-2.2.1$ ls -la plugins/
total 72
drwxr-xr-x 18 ubuntu ubuntu 4096 Sep  7 23:11 .
drwxr-xr-x 11 ubuntu ubuntu 4096 Sep  7 23:10 ..
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-alerting
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-anomaly-detection
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-asynchronous-search
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-cross-cluster-replication
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-geospatial
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-index-management
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-job-scheduler
drwxr-xr-x  3 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-knn
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-ml
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-notifications
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-notifications-core
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-observability
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-performance-analyzer
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-reports-scheduler
drwxr-xr-x  2 ubuntu ubuntu 4096 Aug 30 18:19 opensearch-sql
drwxr-xr-x  2 ubuntu ubuntu 4096 Sep  7 23:06 repository-s3

[1] https://github.com/opensearch-project/opensearch-plugins/blob/main/CONVENTIONS.md#folders

@saratvemulapalli do you know how the folder name is established? My overarching goal is to make sure that all the plugins are following this convention. I had assumed that it is based on the folder structure within each repo. Also, we need to be more specific in the convention verbiage in order to prevent someone else from making this same mistake.

@saratvemulapalli
Copy link
Member

@saratvemulapalli do you know how the folder name is established? My overarching goal is to make sure that all the plugins are following this convention. I had assumed that it is based on the folder structure within each repo.

@mnkugler plugin name is defined by a property[1] which populates plugin-descriptor.properties[2]. This plugin-descriptor.properties file is read by the bin/opensearch-plugin install tool and creates the folder. This blog post is a good read[3]

Also, we need to be more specific in the convention verbiage in order to prevent someone else from making this same mistake.

💯 % I agree with you. Would you like to make the change in this PR?

[1] https://github.com/opensearch-project/anomaly-detection/blob/main/build.gradle#L191
[2] https://github.com/opensearch-project/anomaly-detection/blob/main/src/main/resources/plugin-descriptor.properties#L16
[3] https://opensearch.org/blog/technical-post/2021/12/plugins-intro/

@wbeckler
Copy link

wbeckler commented Dec 9, 2022

@saratvemulapalli given what you've explained, the folder-related convention is redundant and confusing. This is because the name in plugin-descriptor.properties is all that matters in terms of folder naming.

I think this PR should be accepted, as it removes the potential for confusion.

@saratvemulapalli
Copy link
Member

@saratvemulapalli given what you've explained, the folder-related convention is redundant and confusing. This is because the name in plugin-descriptor.properties is all that matters in terms of folder naming.

I think this PR should be accepted, as it removes the potential for confusion.

@wbeckler Thinking about it, that makes sense.

@saratvemulapalli saratvemulapalli merged commit f0fb80e into opensearch-project:main Dec 9, 2022
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.

4 participants