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

Added cookbook to increment versions across all plugins. #119

Merged
merged 10 commits into from
Jan 5, 2022

Conversation

dblock
Copy link
Member

@dblock dblock commented Dec 17, 2021

Signed-off-by: dblock dblock@amazon.com

Description

This is what I had to do to make a 1.2.3 build.

Issues Resolved

Coming from opensearch-project/opensearch-build#1365.

Check List

  • Commits are signed per the DCO using --signoff

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.

@dblock dblock marked this pull request as ready for review December 17, 2021 23:53
peternied
peternied previously approved these changes Dec 18, 2021
Copy link
Member

@peternied peternied 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 writing this all up

@dblock
Copy link
Member Author

dblock commented Dec 18, 2021

This is now complete given that opensearch-project/opensearch-build#1380 passed all tests. Ready for CR/merge @peternied @saratvemulapalli.

@dblock dblock requested a review from CEHENKLE December 18, 2021 16:11
@dblock
Copy link
Member Author

dblock commented Dec 18, 2021

@saratvemulapalli @peternied @peterzhuamazon Do you know/think release notes is also something one person can do across all plugins? If so, can you please help me with a cookbook on top of this?

@davidlago
Copy link

davidlago commented Dec 20, 2021

@dblock for release notes, this is what we do in the security plugin (using 1.2.3 as an example to make the step-by-step explanation easier):

  1. Get a diff from 1.2 branch's HEAD and tag 1.2.2.0
  2. Figure out the list of PRs that were merged in that window
  3. Classify them between features, bug fixes and maintenance (sometimes this can be inferred from the related issue's tags, but this is mostly a manual step for now. If we were to automate this, we would have to be able to fully trust 1) all PRs have an associated issue and 2) all issues have (among others) a tag that helps with this classification. This is not true today.
  4. Create a new release notes file (this could be easily "templatized") with a list of changes grouped by category
  5. PR out to main with the release notes file. This will be cherry-picked into 1.2 before creating the 1.2.3.0 tag

Signed-off-by: dblock <dblock@amazon.com>
Signed-off-by: dblock <dblock@amazon.com>
Signed-off-by: dblock <dblock@amazon.com>
Signed-off-by: dblock <dblock@amazon.com>
@dblock dblock force-pushed the increment-versions branch 2 times, most recently from 6ab6f09 to 162f8e2 Compare December 21, 2021 12:42
Signed-off-by: dblock <dblock@dblock.org>
Signed-off-by: dblock <dblock@dblock.org>
META.md Outdated Show resolved Hide resolved
bbarani
bbarani previously approved these changes Dec 22, 2021
…rch is true for any version.

Signed-off-by: dblock <dblock@amazon.com>
META.md Outdated
```
find . -name build.gradle -print0 | xargs -0 sed -i "s/1.2.2/1.2.3/g"
find . -name CMakeLists.txt -print0 | xargs -0 sed -i "s/1.2.2.0/1.2.3.0/g"
find . -name pom.xml -print0 | xargs -0 sed -i "s/1.2.2/1.2.3/g"
Copy link

@davidlago davidlago Dec 23, 2021

Choose a reason for hiding this comment

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

Beware of blanket find/replace statements. In security, for example, bumping from 1.2.3 to 1.2.4 would have also matched this https://github.com/opensearch-project/security/blob/main/pom.xml#L81

Copy link
Member Author

Choose a reason for hiding this comment

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

Fair enough! I think it’s a poor man’s implementation anyway. What we really need is GHA workflows in each repo that increment versions based on created tags.

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

+1 to the component specific actions. It makes it easier for component owners.

@dblock
Copy link
Member Author

dblock commented Jan 3, 2022

@saratvemulapalli @peternied Can I please get a CR on this?

Copy link
Member

@saratvemulapalli saratvemulapalli left a comment

Choose a reason for hiding this comment

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

Thanks @dblock this is really helpful.
Dropped a minor comment.

META.md Outdated
```
find . -name build.gradle -print0 | xargs -0 sed -i "s/1.2.2/1.2.3/g"
find . -name CMakeLists.txt -print0 | xargs -0 sed -i "s/1.2.2.0/1.2.3.0/g"
find . -name pom.xml -print0 | xargs -0 sed -i "s/1.2.2/1.2.3/g"
Copy link
Member

Choose a reason for hiding this comment

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

+1 to the component specific actions. It makes it easier for component owners.

META.md Outdated
```
meta git update
meta git pull origin
meta git checkout 1.2
Copy link
Member

Choose a reason for hiding this comment

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

Not a blocker for this PR, just a thought.
I think having an ENV variable for these versions might make it easier when we run this for future versions.

Copy link
Member Author

Choose a reason for hiding this comment

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

This is a good idea, did it anyway.

Signed-off-by: dblock <dblock@amazon.com>
Signed-off-by: dblock <dblock@amazon.com>
@dblock
Copy link
Member Author

dblock commented Jan 5, 2022

@saratvemulapalli @peternied Re-check please?

Signed-off-by: dblock <dblock@amazon.com>
@dblock dblock merged commit f4fb593 into opensearch-project:main Jan 5, 2022
@dblock dblock deleted the increment-versions branch January 5, 2022 20:13
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.

5 participants