Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
104823: row: remove leftover reference to TestingSQLCodec in a test r=yuzefovich a=yuzefovich

This was missed in #82890.

Addresses: #48123.
Epic: None

Release note: None

104893: build: upgrade go to 1.19.10 r=srosenberg a=rail

* [ ] Adjust the Pebble tests to run in new version.
* [x] Adjust version in Docker image ([source](./builder/Dockerfile)).
* [x] Adjust version in the TeamCity agent image ([setup script](./packer/teamcity-agent.sh))
* [x] Rebuild and push the Docker image (following [Basic Process](#basic-process))
* [x] Update `build/teamcity/internal/release/build-and-publish-patched-go/impl.sh` with the new version and adjust SHA256 sums as necessary.
* [x] Adjust `GO_VERSION` and `GO_FIPS_COMMIT` for the FIPS Go toolchain ([source](./teamcity/internal/release/build-and-publish-patched-go/impl-fips.sh)).
* [x] Run the `Internal / Cockroach / Build / Toolchains / Publish Patched Go for Mac` build configuration in TeamCity with your latest version of the script above. Note the job depends on another job `Build and Publish Patched Go`. That job prints out the SHA256 of all tarballs, which you will need to copy-paste into `WORKSPACE` (see below). `Publish Patched Go for Mac` is an extra step that publishes the *signed* `go` binaries for macOS. That job also prints out the SHA256 of the Mac tarballs in particular.
* [x] Adjust `--`@io_bazel_rules_go//go/toolchain:sdk_version`` in [.bazelrc](../.bazelrc).
* [x] Bump the version in `WORKSPACE` under `go_download_sdk`. You may need to bump [rules_go](https://github.com/bazelbuild/rules_go/releases). Also edit the filenames listed in `sdks` and update all the hashes to match what you built in the step above.
* [x] Bump the version in `WORKSPACE` under `go_download_sdk` for the FIPS version of Go (`go_sdk_fips`).
* [x] Run `./dev generate bazel` to refresh `distdir_files.bzl`, then `bazel fetch `@distdir//:archives`` to ensure you've updated all hashes to the correct value.
* [x] Bump the version in `builder.sh` accordingly ([source](./builder.sh#L6)).
* [ ] Bump the version in `go-version-check.sh` ([source](./go-version-check.sh)), unless bumping to a new patch release.
* [ ] Bump the go version in `go.mod`.
* [x] Bump the default installed version of Go in `bootstrap-debian.sh` ([source](./bootstrap/bootstrap-debian.sh)).
* [x] Replace other mentions of the older version of go (grep for `golang:<old_version>` and `go<old_version>`).
* [ ] Update the `builder.dockerImage` parameter in the TeamCity [`Cockroach`](https://teamcity.cockroachdb.com/admin/editProject.html?projectId=Cockroach&tab=projectParams) and [`Internal`](https://teamcity.cockroachdb.com/admin/editProject.html?projectId=Internal&tab=projectParams) projects.
* [ ] Ask the Developer Infrastructure team to deploy new TeamCity agent images according to [packer/README.md](./packer/README.md)

Epic: none
Release note: None

Co-authored-by: Yahor Yuzefovich <yahor@cockroachlabs.com>
Co-authored-by: Rail Aliiev <rail@iqchoice.com>
  • Loading branch information
3 people committed Jun 14, 2023
3 parents 1d3c777 + ef1ba50 + a6e8fbd commit 5741b95
Show file tree
Hide file tree
Showing 12 changed files with 33 additions and 35 deletions.
2 changes: 1 addition & 1 deletion .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ build:crosslinuxfips '--workspace_status_command=./build/bazelutil/stamp.sh x86_
build:crosslinuxfips --config=crosslinuxfipsbase
build:crosslinuxfipsbase --platforms=//build/toolchains:cross_linux
build:crosslinuxfipsbase --config=cross
build:crosslinuxfipsbase --@io_bazel_rules_go//go/toolchain:sdk_version=1.19.8fips
build:crosslinuxfipsbase --@io_bazel_rules_go//go/toolchain:sdk_version=1.19.10fips
build:crosswindows '--workspace_status_command=./build/bazelutil/stamp.sh x86_64-w64-mingw32'
build:crosswindows --config=crosswindowsbase
build:crosswindowsbase --platforms=//build/toolchains:cross_windows
Expand Down
22 changes: 11 additions & 11 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -162,15 +162,15 @@ load(
go_download_sdk(
name = "go_sdk",
sdks = {
"darwin_amd64": ("go1.19.4.darwin-amd64.tar.gz", "e88ffbbfe3adc94c4a2cf50f24e698a4c262cd99d98ea7d02d289726106d61e7"),
"darwin_arm64": ("go1.19.4.darwin-arm64.tar.gz", "1408a938fef3d17163d585db6bc2b769835c801302e3efc05ffabe021c05f0e9"),
"freebsd_amd64": ("go1.19.4.freebsd-amd64.tar.gz", "84489ebb63f1757b79574d7345c647bd40bc6414cecb868c93e24476c2d2b9b6"),
"linux_amd64": ("go1.19.4.linux-amd64.tar.gz", "565b0c97ea85539951daf203be166aef1e96e4e1bf38498a9ef5443298d83b7a"),
"linux_arm64": ("go1.19.4.linux-arm64.tar.gz", "6bb5752483c0d145b91199e5cc1352960d926850e75864dea16282337b0d92fe"),
"windows_amd64": ("go1.19.4.windows-amd64.tar.gz", "0f37edf2a6663db33c8f67ee36e21a7eb391fbf35d494299f6a81a59e294f4a0"),
"darwin_amd64": ("go1.19.10.darwin-amd64.tar.gz", "0b298b1c3e89357c86825f375928e6e9d41ad84c7d7b190a2a6730e0706165b3"),
"darwin_arm64": ("go1.19.10.darwin-arm64.tar.gz", "7cc8ab7e8e1225b57f44ec8fb26bce70ddea8e076dfdf118ed63fef0c9ff19fb"),
"freebsd_amd64": ("go1.19.10.freebsd-amd64.tar.gz", "0d22265662eaa9b8136223f8ab68f5c06c58c6a6311748fb810e830ebd17cbe2"),
"linux_amd64": ("go1.19.10.linux-amd64.tar.gz", "dfc8a696686d00065ba374209a3a7858926641e0fb55741dd89c357446d69a1e"),
"linux_arm64": ("go1.19.10.linux-arm64.tar.gz", "e36d6ebfce3f244e245a2969f83d26c8dff2bf8b72207822d9d66829cd93d067"),
"windows_amd64": ("go1.19.10.windows-amd64.tar.gz", "dab9df83e0768ff96eddd85a4def88db05ce5a8a0c439abcecd066888906c516"),
},
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/{}"],
version = "1.19.4",
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/{}"],
version = "1.19.10",
)

# To point to a local SDK path, use the following instead. We'll call the
Expand Down Expand Up @@ -657,8 +657,8 @@ distdir_repositories()
go_download_sdk(
name = "go_sdk_fips",
sdks = {
"linux_amd64": ("go1.19.8fips.linux-amd64.tar.gz", "8170fd871cb61dc771ec1f309451b31a73d5aca3410dfa9d952672ae2be4ac9e"),
"linux_amd64": ("go1.19.10fips.linux-amd64.tar.gz", "c9348fc964fb2893471a6ba91feead205a6f83cd427bc3847949382417005496"),
},
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230427-165819/{}"],
version = "1.19.8fips",
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/{}"],
version = "1.19.10fips",
)
14 changes: 7 additions & 7 deletions build/bazelutil/distdir_files.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -1165,13 +1165,13 @@ DISTDIR_FILES = {
"https://storage.googleapis.com/public-bazel-artifacts/c-deps/20230105-170607/libproj_foreign.macos.20230105-170607.tar.gz": "7706dcc20f083f621ba891eb82864e980ae352f34add33753100085d12ab91ec",
"https://storage.googleapis.com/public-bazel-artifacts/c-deps/20230105-170607/libproj_foreign.macosarm.20230105-170607.tar.gz": "1ab617eb51b017d27d71ba08a065b6a08ef5410e9aa5554669196b7cf28214c1",
"https://storage.googleapis.com/public-bazel-artifacts/c-deps/20230105-170607/libproj_foreign.windows.20230105-170607.tar.gz": "b819b17740b2a3418d62d2f6db8b245094458180e1e5e301e9f0f4257696fef5",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/go1.19.4.darwin-amd64.tar.gz": "e88ffbbfe3adc94c4a2cf50f24e698a4c262cd99d98ea7d02d289726106d61e7",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/go1.19.4.darwin-arm64.tar.gz": "1408a938fef3d17163d585db6bc2b769835c801302e3efc05ffabe021c05f0e9",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/go1.19.4.freebsd-amd64.tar.gz": "84489ebb63f1757b79574d7345c647bd40bc6414cecb868c93e24476c2d2b9b6",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/go1.19.4.linux-amd64.tar.gz": "565b0c97ea85539951daf203be166aef1e96e4e1bf38498a9ef5443298d83b7a",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/go1.19.4.linux-arm64.tar.gz": "6bb5752483c0d145b91199e5cc1352960d926850e75864dea16282337b0d92fe",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230214-214430/go1.19.4.windows-amd64.tar.gz": "0f37edf2a6663db33c8f67ee36e21a7eb391fbf35d494299f6a81a59e294f4a0",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230427-165819/go1.19.8fips.linux-amd64.tar.gz": "8170fd871cb61dc771ec1f309451b31a73d5aca3410dfa9d952672ae2be4ac9e",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.darwin-amd64.tar.gz": "0b298b1c3e89357c86825f375928e6e9d41ad84c7d7b190a2a6730e0706165b3",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.darwin-arm64.tar.gz": "7cc8ab7e8e1225b57f44ec8fb26bce70ddea8e076dfdf118ed63fef0c9ff19fb",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.freebsd-amd64.tar.gz": "0d22265662eaa9b8136223f8ab68f5c06c58c6a6311748fb810e830ebd17cbe2",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.linux-amd64.tar.gz": "dfc8a696686d00065ba374209a3a7858926641e0fb55741dd89c357446d69a1e",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.linux-arm64.tar.gz": "e36d6ebfce3f244e245a2969f83d26c8dff2bf8b72207822d9d66829cd93d067",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.windows-amd64.tar.gz": "dab9df83e0768ff96eddd85a4def88db05ce5a8a0c439abcecd066888906c516",
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10fips.linux-amd64.tar.gz": "c9348fc964fb2893471a6ba91feead205a6f83cd427bc3847949382417005496",
"https://storage.googleapis.com/public-bazel-artifacts/gomod/github.com/bazelbuild/buildtools/v6.1.2-0-gb182fc4/bazelbuild-buildtools-v6.1.2-0-gb182fc4.tar.gz": "d71a889e3bc50cc8b9d42c859e15a74f7c8d10b6786f8dd82f08f2bf24e5bdc6",
"https://storage.googleapis.com/public-bazel-artifacts/java/railroad/rr-1.63-java8.zip": "d2791cd7a44ea5be862f33f5a9b3d40aaad9858455828ebade7007ad7113fb41",
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_jest-v0.18.4.tar.gz": "d3bb833f74b8ad054e6bff5e41606ff10a62880cc99e4d480f4bdfa70add1ba7",
Expand Down
4 changes: 2 additions & 2 deletions build/bootstrap/bootstrap-debian.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ sudo tar -C /usr --strip-components=1 -zxf /tmp/cmake.tgz && rm /tmp/cmake.tgz

# Install Go.
trap 'rm -f /tmp/go.tgz' EXIT
curl -fsSL https://dl.google.com/go/go1.19.4.linux-amd64.tar.gz > /tmp/go.tgz
curl -fsSL https://dl.google.com/go/go1.19.10.linux-amd64.tar.gz > /tmp/go.tgz
sha256sum -c - <<EOF
c9c08f783325c4cf840a94333159cc937f05f75d36a8b307951d5bd959cf2ab8 /tmp/go.tgz
8b045a483d3895c6edba2e90a9189262876190dbbd21756870cdd63821810677 /tmp/go.tgz
EOF
sudo tar -C /usr/local -zxf /tmp/go.tgz && rm /tmp/go.tgz

Expand Down
2 changes: 1 addition & 1 deletion build/builder.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
set -euo pipefail

image=cockroachdb/builder
version=20230103-212639
version=20230614-164006

function init() {
docker build --tag="${image}" "$(dirname "${0}")/builder"
Expand Down
4 changes: 2 additions & 2 deletions build/builder/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,8 @@ RUN curl -fsSL https://github.com/Kitware/CMake/releases/download/v3.20.3/cmake-
# releases of Go will no longer be run in CI once it is changed. Consider
# bumping the minimum allowed version of Go in /build/go-version-check.sh.
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends golang \
&& curl -fsSL https://storage.googleapis.com/golang/go1.19.4.src.tar.gz -o golang.tar.gz \
&& echo 'eda74db4ac494800a3e66ee784e495bfbb9b8e535df924a8b01b1a8028b7f368 golang.tar.gz' | sha256sum -c - \
&& curl -fsSL https://storage.googleapis.com/golang/go1.19.10.src.tar.gz -o golang.tar.gz \
&& echo '13755bcce529747d5f2930dee034730c86d02bd3e521ab3e2bbede548d3b953f golang.tar.gz' | sha256sum -c - \
&& tar -C /usr/local -xzf golang.tar.gz \
&& rm golang.tar.gz \
&& cd /usr/local/go/src \
Expand Down
4 changes: 2 additions & 2 deletions build/packer/teamcity-agent.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ tar --strip-components=1 -C /usr -xzf /tmp/cmake.tar.gz
rm -f /tmp/cmake.tar.gz

if [ $ARCH = x86_64 ]; then
curl -fsSL https://dl.google.com/go/go1.19.4.linux-amd64.tar.gz > /tmp/go.tgz
curl -fsSL https://dl.google.com/go/go1.19.10.linux-amd64.tar.gz > /tmp/go.tgz
sha256sum -c - <<EOF
c9c08f783325c4cf840a94333159cc937f05f75d36a8b307951d5bd959cf2ab8 /tmp/go.tgz
8b045a483d3895c6edba2e90a9189262876190dbbd21756870cdd63821810677 /tmp/go.tgz
EOF
tar -C /usr/local -zxf /tmp/go.tgz && rm /tmp/go.tgz

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ set -xeuo pipefail
# TODO: We may want to fork this repo and keep it up to date.
GO_FIPS_REPO=https://github.com/golang-fips/go
GO_FIPS_COMMIT=go1.19-fips-release
GO_VERSION=1.19.8
GO_VERSION=1.19.10

# Install build dependencies
yum install git golang golang-bin openssl openssl-devel -y
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
set -xeuo pipefail

# When updating to a new Go version, update all of these variables.
GOVERS=1.19.4
GOVERS=1.19.10
GOLINK=https://go.dev/dl/go$GOVERS.src.tar.gz
SRCSHASUM=eda74db4ac494800a3e66ee784e495bfbb9b8e535df924a8b01b1a8028b7f368
SRCSHASUM=13755bcce529747d5f2930dee034730c86d02bd3e521ab3e2bbede548d3b953f
# We mirror the upstream freebsd because we don't have a cross-compiler targeting it.
GOFREEBSDLINK=https://go.dev/dl/go$GOVERS.freebsd-amd64.tar.gz
FREEBSDSHASUM=84489ebb63f1757b79574d7345c647bd40bc6414cecb868c93e24476c2d2b9b6
FREEBSDSHASUM=0d22265662eaa9b8136223f8ab68f5c06c58c6a6311748fb810e830ebd17cbe2

apt-get update
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
Expand Down
4 changes: 2 additions & 2 deletions pkg/cmd/roachtest/tests/go_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@ func installGolang(
}

if err := repeatRunE(
ctx, t, c, node, "download go", `curl -fsSL https://dl.google.com/go/go1.19.4.linux-amd64.tar.gz > /tmp/go.tgz`,
ctx, t, c, node, "download go", `curl -fsSL https://dl.google.com/go/go1.19.10.linux-amd64.tar.gz > /tmp/go.tgz`,
); err != nil {
t.Fatal(err)
}
if err := repeatRunE(
ctx, t, c, node, "verify tarball", `sha256sum -c - <<EOF
c9c08f783325c4cf840a94333159cc937f05f75d36a8b307951d5bd959cf2ab8 /tmp/go.tgz
8b045a483d3895c6edba2e90a9189262876190dbbd21756870cdd63821810677 /tmp/go.tgz
EOF`,
); err != nil {
t.Fatal(err)
Expand Down
1 change: 0 additions & 1 deletion pkg/sql/row/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,6 @@ go_test(
"//pkg/sql/sem/tree",
"//pkg/storage",
"//pkg/testutils",
"//pkg/testutils/keysutils",
"//pkg/testutils/serverutils",
"//pkg/testutils/sqlutils",
"//pkg/util/encoding",
Expand Down
3 changes: 1 addition & 2 deletions pkg/sql/row/expr_walker_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/isql"
"github.com/cockroachdb/cockroach/pkg/sql/row"
"github.com/cockroachdb/cockroach/pkg/sql/sem/eval"
"github.com/cockroachdb/cockroach/pkg/testutils/keysutils"
"github.com/cockroachdb/cockroach/pkg/testutils/serverutils"
"github.com/cockroachdb/cockroach/pkg/util/leaktest"
"github.com/cockroachdb/cockroach/pkg/util/log"
Expand Down Expand Up @@ -202,7 +201,7 @@ func TestJobBackedSeqChunkProvider(t *testing.T) {
}

for id, val := range test.seqIDToExpectedVal {
seqDesc := createAndIncrementSeqDescriptor(ctx, t, id, keysutils.TestingSQLCodec,
seqDesc := createAndIncrementSeqDescriptor(ctx, t, id, evalCtx.Codec,
test.incrementBy, test.seqIDToOpts[id], kvDB)
seqMetadata := &row.SequenceMetadata{
SeqDesc: seqDesc,
Expand Down

0 comments on commit 5741b95

Please sign in to comment.