Skip to content

Commit

Permalink
Merge branch 'v8' into moshe/lower.memory.usage
Browse files Browse the repository at this point in the history
  • Loading branch information
moshegood authored Feb 13, 2024
2 parents 52ff6a5 + 17af73f commit 2ea42ef
Show file tree
Hide file tree
Showing 9 changed files with 79 additions and 54 deletions.
21 changes: 0 additions & 21 deletions .github/ISSUE_TEMPLATE/update_go_versions.md

This file was deleted.

4 changes: 2 additions & 2 deletions .github/variables/go-versions.env
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
latest=1.21.6
penultimate=1.20.13
latest=1.22.0
penultimate=1.21.7
58 changes: 37 additions & 21 deletions .github/workflows/check-go-versions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,16 @@ on:
schedule:
- cron: "0 17 * * *"
workflow_dispatch:
inputs:
force_create_issue:
type: boolean
description: 'Create issue even if versions are up-to-date'
required: false
default: false

jobs:
go-versions:
uses: ./.github/workflows/go-versions.yml

check-go-eol:
needs: go-versions
permissions:
issues: write
contents: read
contents: write
pull-requests: write
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
Expand All @@ -36,17 +31,38 @@ jobs:
echo "officialLatestVersion=${{ fromJSON(env.fetch-api-data)[0].latest }}" >> $GITHUB_ENV
echo "officialPenultimateVersion=${{ fromJSON(env.fetch-api-data)[1].latest }}" >> $GITHUB_ENV
# If the latest official Go version is different from Relay's release version, generate an issue
# with useful details.
- name: Create issue if update required
if: inputs.force_create_issue || (needs.go-versions.outputs.latest != env.officialLatestVersion)
uses: JasonEtco/create-an-issue@e27dddc79c92bc6e4562f268fffa5ed752639abd
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RELAY_LATEST_VERSION: ${{ needs.go-versions.outputs.latest }}
OFFICIAL_LATEST_VERSION: ${{ env.officialLatestVersion }}
RELAY_PENULTIMATE_VERSION: ${{ needs.go-versions.outputs.penultimate }}
OFFICIAL_PENULTIMATE_VERSION: ${{ env.officialPenultimateVersion }}
- name: Run update script
if: needs.go-versions.outputs.latest != env.officialLatestVersion
id: update
run: ./scripts/update-go-release-version.sh ${{ env.officialLatestVersion }} ${{ env.officialPenultimateVersion }} \

- name: Create pull request
if: steps.update.outcome == 'success'
uses: peter-evans/create-pull-request@v6
with:
filename: .github/ISSUE_TEMPLATE/update_go_versions.md
update_existing: true
token: ${{ secrets.GITHUB_TOKEN }}
add-paths: |
Dockerfile
.github/variables/go-versions.env
branch: "launchdarklyreleasebot/update-to-go-${{ env.officialLatestVersion }}"
author: "LaunchDarklyReleaseBot <[email protected]>"
committer: "LaunchDarklyReleaseBot <[email protected]>"
title: "fix(deps): bump supported Go versions to ${{ env.officialLatestVersion }} and ${{ env.officialPenultimateVersion }}"
commit-message: "Bumps from Go ${{ needs.go-versions.outputs.latest }} -> ${{ env.officialLatestVersion }} and ${{ needs.go-versions.outputs.penultimate }} -> ${{ env.officialPenultimateVersion }}."
body: |
It's time to update Relay's supported Go versions, due to a recent upstream Go release.
The Go major release cadence is ~every 6 months; the two most recent major versions are supported.
Note that between major releases, the Go team often ships multiple minor versions.
| | Current repo configuration | Desired repo configuration |
|-------------|------------------------------------|---------------------------------------------------------------------------------------------------------------------|
| Latest | ${{ needs.go-versions.outputs.latest }} | [${{ env.officialLatestVersion }}](https://go.dev/doc/devel/release#go${{ env.officialLatestVersion }}) |
| Penultimate | ${{ needs.go-versions.outputs.penultimate }}| [${{ env.officialPenultimateVersion }}](https://go.dev/doc/devel/release#go${{ env.officialPenultimateVersion }}) |
Run locally:
```bash
./scripts/update-go-release-version.sh ${{ env.officialPenultimateVersion }} ${{ env.officialPenultimateVersion }}
```
11 changes: 4 additions & 7 deletions .github/workflows/daily-integration-tests.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
name: 'Integration Tests'
name: 'Daily Integration Tests'
on:
workflow_dispatch:
inputs:
go-version:
description: "Go version to use for building Relay."
required: false
type: string
branch:
description: "Branch to test."
description: "Go version to use for building Relay (leave empty for latest defined in repo.)"
required: false
type: string

Expand All @@ -25,9 +21,10 @@ jobs:
fail-fast: false
matrix:
environment: ['staging', 'production']
branch: ['v7', 'v8']

uses: ./.github/workflows/integration-test.yml
with:
environment: ${{ matrix.environment }}
go-version: ${{ inputs.go-version != '' && inputs.go-version || needs.go-versions.outputs.latest }}
branch: ${{ inputs.branch }}
branch: ${{ matrix.branch }}
26 changes: 26 additions & 0 deletions .github/workflows/manual-integration-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: 'Manual Integration Tests'
on:
workflow_dispatch:
inputs:
go-version:
description: "Go version to use for building Relay (leave empty for latest defined in repo.)"
required: false
type: string
environment:
description: "The environment to test against."
type: choice
options:
- 'staging'
- 'production'

jobs:
go-versions:
uses: ./.github/workflows/go-versions.yml

integration-test:
needs: go-versions
uses: ./.github/workflows/integration-test.yml
with:
environment: ${{ inputs.environment }}
go-version: ${{ inputs.go-version != '' && inputs.go-version || needs.go-versions.outputs.latest }}
branch: ${{ github.ref }}
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "8.3.0"
".": "8.3.1"
}
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

All notable changes to the LaunchDarkly Relay will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org).

## [8.3.1](https://github.com/launchdarkly/ld-relay/compare/v8.3.0...v8.3.1) (2024-02-12)


### Bug Fixes

* **deps:** bump supported Go versions to 1.22.0 and 1.21.7 ([#314](https://github.com/launchdarkly/ld-relay/issues/314)) ([e81454f](https://github.com/launchdarkly/ld-relay/commit/e81454f097d46f487d870dd1f286e9101fab8bec))

## [8.3.0](https://github.com/launchdarkly/ld-relay/compare/v8.2.3...v8.3.0) (2024-02-09)


Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# This is a standalone Dockerfile that does not depend on goreleaser building the binary
# It is NOT the version that is pushed to dockerhub
FROM golang:1.21.6-alpine3.19 as builder
FROM golang:1.22.0-alpine3.19 as builder
# See "Runtime platform versions" in CONTRIBUTING.md

RUN apk --no-cache add \
Expand Down
2 changes: 1 addition & 1 deletion relay/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
package version

// Version is the package version
const Version = "8.3.0" // {{ x-release-please-version }}
const Version = "8.3.1" // {{ x-release-please-version }}

0 comments on commit 2ea42ef

Please sign in to comment.