screwdriver-cd / screwdriver

An open source build platform designed for continuous delivery.
http://screwdriver.cd
Other
1.02k stars 169 forks source link

Screwdriver's Version Numbers #900

Open stjohnjohnson opened 6 years ago

stjohnjohnson commented 6 years ago

note: this is partially inspired by the npm version mishap that happened this past week

Screwdriver has some strange version numbers (as of 2/23):

What version is Screwdriver at? What version should I be using?

It's clear that our versioning is really all over the place when it comes to user-facing resources. For our internal node modules or binaries I think we do a good job. So what can we do to make a better experience for those trying to consume our product?

First-pass Proposal

At the end of the day, our users should be able to see the latest stable version of Screwdriver, what version they are on, what changed between then and now, and what they need to do to upgrade. All of that should be available somewhere on screwdriver-cd/screwdriver.

Research notes

Other OSS projects do things like:

petey commented 6 years ago

I agree with shipping out consistently versioned docker images for our projects, and divorcing those versions from the versions of the apps they contain.

I'm not a fan of even/odd versions, or having multiple active long-lived branches. I think that just leads to confusion. I'd much rather we adopted a train model where we ship master every [six] weeks (minor version) or more frequently (patch releases for bug fixes), and always provide backwards compatibility for deprecated features with deprecation warnings. After some period of time, we remove those deprecated features and warnings and bump major/minor.

As always, changelogs for the system-as-a-whole and each component therein are a necessity.

FenrirUnbound commented 6 years ago

Separating docker images from the modules is something I completely agree with.

One thing I would add to your research is the common use of docker-specific repositories projects use. Examples are:

As for separate release lines, I've worked on different projects that have taken both approaches. The largest difference that I've seen between the two is the maintenance efforts are different, and developers respect them differently. For example, folks that aren't confident in cherry-picking releases definitely won't enjoy supporting multiple release lines.

stjohnjohnson commented 6 years ago

Thanks for the feedback. I'm circling back on this because I've run into some fun issues using stable in Kubernetes because it's a floating tag. Some nodes have one version and others have a different version. Therefore I need to go and specify the exact tag I want to use on each system.

So let's review some feedback:

How can we proceed with this? Let's assume that right now the version of Screwdriver is 4.0.74 (the highest of the ones I listed above). What can we do to consistently build 4.0.74 docker images of the UI, API, Store, and Launcher? Should we move them all into the API repo? Make a separate repo like @FenrirUnbound gave as an example?

jithine commented 6 years ago

Proposal.

  1. API already have /versions end point. Enhance it to add a new field version

    {
    ...
    version: 5.1.2
    ...
    }
  2. Define POST /versions which will be invoked as part of release process, which bumps up major/minor/patch as required. We will have to figure out how separate running release pipelines for API/Store/UI interacts and updates this to a single value.

  3. While we create docker tags for various componets, refer to { GET /versions }.version and use that value to tag UI, API & Store

  4. UI will show this version in footer as version for Screwdriver application. Clicking on version should show all changes in that version. Could be just an API end point which just shows version changes on individual libraries which makes Screwdriver. Related to https://github.com/screwdriver-cd/screwdriver/issues/485