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 automatic release support #1024

Merged
merged 7 commits into from
Mar 20, 2020
Merged

Add automatic release support #1024

merged 7 commits into from
Mar 20, 2020

Conversation

carlosalberto
Copy link
Contributor

Fixes #971

We still need to manually update the version field in build.gradle, but once that is done, creating a branch starting with v. triggers a deployment to Bintray/Maven Central.

See https://github.com/open-telemetry/opentelemetry-java/releases/tag/v0.2.4 as an example (I used this one to verify all works great).

In a future we can play with plugins that automatically update the version and create a tag (such as the Maven Release plugin does).

PS - I'd like to stop repeating all the steps in the different tasks if possible (now we have very similar build, java11 and release tasks). But we need somebody who is a Circle wizard or one who digs enough into this. Anyway, something to do in the future.

@pavolloffay
Copy link
Member

@carlosalberto could we have RELEASE.md that describes what a user has to do to release the artifacts to maven central? Maybe also explain what happens in behind the scenes. It is also useful to have a command for releasing locally if something goes wrong.

In jaeger java client (gradle based) we have fully automated release from travis to maven central. It's done by pushing a release tag. The artifact version is kept in gradle.properties and the deploy scripts does similar checks like we were doing in OT ecosystem.

https://github.com/jaegertracing/jaeger-client-java/blob/master/RELEASE.md#automatic-release-preferred
https://github.com/jaegertracing/jaeger-client-java/blob/master/gradle.properties
https://github.com/jaegertracing/jaeger-client-java/blob/master/travis/deploy.sh

https://github.com/jaegertracing/jaeger-client-java/blob/master/travis/deploy.sh

@carlosalberto
Copy link
Contributor Author

@pavolloffay Great idea, lets definitely do that.

A local command is also available at this moment, so I will include the explanation in such document (however, user will have to provide his/her credentials, but I guess that's taken for granted).

I will do a follow-up on the more-automated part after we get this one merged ;)

@carlosalberto
Copy link
Contributor Author

@pavolloffay Added a small RELEASE.md file with the current workflow. I suggest we iterate on the more automated work in a follow up PR, as previously stated ;)

@carlosalberto
Copy link
Contributor Author

@open-telemetry/java-approvers Please review/approve this PR.

RELEASE.md Outdated Show resolved Hide resolved
Copy link
Member

@pavolloffay pavolloffay left a comment

Choose a reason for hiding this comment

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

The release should be also marked on Github and probably with copied the changelog for that version.

RELEASE.md Show resolved Hide resolved
@carlosalberto
Copy link
Contributor Author

carlosalberto commented Mar 19, 2020

The release should be also marked on Github and probably with copied the changelog for that version.

Sure, we can do that when doing the fully automatized version (that is, right after 0.3.0 and definitely before 1.0)

@pavolloffay
Copy link
Member

I mean it should be documented to do that, I am not sure if there is gradle tooling that can update the changelog on Github.

@carlosalberto
Copy link
Contributor Author

Updated. @bogdandrutu Verify and merge.

@bogdandrutu bogdandrutu merged commit 6f0c44a into master Mar 20, 2020
@bogdandrutu bogdandrutu deleted the add_automatic_release branch March 20, 2020 18:00
davebarda pushed a commit to davebarda/opentelemetry-java that referenced this pull request Apr 24, 2020
* Initial support for automatic artifacts release.

* Try out version 0.2.4

* Use 1GB ram as the build task.

* Restore original version.

* Add RELEASE.md

* Minor style fixes.

* Fixes.
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.

automated releases
4 participants