Skip to content

Commit

Permalink
Merge pull request #1 from zhenruyan/master
Browse files Browse the repository at this point in the history
merge Update BUILD.bazel
  • Loading branch information
zhenruyan committed Aug 21, 2023
2 parents 72932d0 + 089f509 commit 5d2bec4
Show file tree
Hide file tree
Showing 281 changed files with 8,967 additions and 2,574 deletions.
26 changes: 22 additions & 4 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,15 @@ test:race --test_timeout=1200,6000,18000,72000
# CI uses a custom timeout for enormous targets.
test:use_ci_timeouts --test_timeout=60,300,900,900 --define=use_ci_timeouts=true
# CI should always run with `--config=ci`.
build:ci --lintonbuild
build:cibase --lintonbuild
# Set `-test.v` in Go tests.
# Ref: https://github.com/bazelbuild/rules_go/pull/2456
test:ci --test_env=GO_TEST_WRAP_TESTV=1
test:cibase --test_env=GO_TEST_WRAP_TESTV=1
# Dump all output for failed tests to the build log.
test:ci --test_output=errors
test:cibase --test_output=errors
# Put all tmp artifacts in /artifacts/tmp.
build:ci --test_tmpdir=/artifacts/tmp
test:ci --test_tmpdir=/artifacts/tmp
build:ci --config=cibase

build:cross --stamp

Expand Down Expand Up @@ -111,6 +112,23 @@ build:macos --host_action_env=PATH=/opt/homebrew/bin:/opt/local/bin:/usr/local/b
# more precise --workspace_status_command option.
build:simplestamp --stamp --workspace_status_command=./build/bazelutil/stamp.sh

build:engflow --define=EXECUTOR=remote
build:engflow --disk_cache=
build:engflow --experimental_inmemory_dotd_files
build:engflow --experimental_inmemory_jdeps_files
build:engflow --incompatible_strict_action_env=true
build:engflow --remote_timeout=600
build:engflow --nolegacy_important_outputs
build:engflow --grpc_keepalive_time=30s
build:engflow --experimental_remote_cache_compression=true
build:engflow --action_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1
build:engflow --remote_cache=grpcs://tanzanite.cluster.engflow.com
build:engflow --remote_executor=grpcs://tanzanite.cluster.engflow.com
build:engflow --bes_backend=grpcs://tanzanite.cluster.engflow.com
build:engflow --bes_results_url=https://tanzanite.cluster.engflow.com/invocation/
build:engflow --extra_execution_platforms=//build/toolchains:cross_linux
test:engflow --test_env=REMOTE_EXEC=1

try-import %workspace%/.bazelrc.user

# vi: ft=sh
62 changes: 62 additions & 0 deletions .github/workflows/update_releases.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Copyright 2023 The Cockroach Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

on:
schedule:
- cron: 0 0 * * *
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:


name: Update pkg/testutils/release/cockroach_releases.yaml
jobs:
update-crdb-releases-yaml:
strategy:
matrix:
branch: ["master", "release-23.1"]
name: Update pkg/testutils/release/cockroach_releases.yaml on ${{ matrix.branch }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: "${{ matrix.branch }}"
- name: Mount bazel cache
uses: actions/cache@v3
with:
path: "~/.cache/bazel"
key: bazel
- name: Check for updates
run: |
bazel build //pkg/cmd/release
$(bazel info bazel-bin)/pkg/cmd/release/release_/release update-releases-file
git diff
- name: Update pkg/testutils/release/cockroach_releases.yaml on ${{ matrix.branch }}
uses: peter-evans/create-pull-request@v5
with:
base: "${{ matrix.branch }}"
branch: 'crdb-releases-yaml-update-${{ matrix.branch }}'
title: "${{ matrix.branch }}: Update pkg/testutils/release/cockroach_releases.yaml"
body: |
Update pkg/testutils/release/cockroach_releases.yaml with recent values.
Epic: None
Release note: None
commit-message: |
${{ matrix.branch }}: Update pkg/testutils/release/cockroach_releases.yaml
Update pkg/testutils/release/cockroach_releases.yaml with recent values.
Epic: None
Release note: None
delete-branch: true
42 changes: 21 additions & 21 deletions DEPS.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -11160,10 +11160,10 @@ def go_deps():
name = "org_golang_x_crypto",
build_file_proto_mode = "disable_global",
importpath = "golang.org/x/crypto",
sha256 = "672ebc916740a040d5f5472b477e1d1898e06b0c6c0a5a820b65495bbb133e82",
strip_prefix = "golang.org/x/crypto@v0.9.0",
sha256 = "2e4f9b72df6f480a744483b14d6b8cbad98ff066399979ac74ff1dc5b74e9bec",
strip_prefix = "golang.org/x/crypto@v0.10.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/crypto/org_golang_x_crypto-v0.9.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/crypto/org_golang_x_crypto-v0.10.0.zip",
],
)
go_repository(
Expand Down Expand Up @@ -11230,10 +11230,10 @@ def go_deps():
name = "org_golang_x_net",
build_file_proto_mode = "disable_global",
importpath = "golang.org/x/net",
sha256 = "f92f9b2655226a6d015af7a76279a11fb55678e410b851b158fc846546f80733",
strip_prefix = "golang.org/x/net@v0.10.0",
sha256 = "5d97db0b34367452949b1b04194b47a663cbb0852f40d119ba5d910ccc124657",
strip_prefix = "golang.org/x/net@v0.11.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.10.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.11.0.zip",
],
)
go_repository(
Expand All @@ -11260,40 +11260,40 @@ def go_deps():
name = "org_golang_x_sync",
build_file_proto_mode = "disable_global",
importpath = "golang.org/x/sync",
sha256 = "f510bec6009e19882d19953e7273137d34df86c65949345d72f123a255c2ecd2",
strip_prefix = "golang.org/x/sync@v0.1.0",
sha256 = "1870e7a196f7119d4c6edba7de9cdfc49ee13c8cb7921f3a947568171c6152e0",
strip_prefix = "golang.org/x/sync@v0.3.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sync/org_golang_x_sync-v0.1.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sync/org_golang_x_sync-v0.3.0.zip",
],
)
go_repository(
name = "org_golang_x_sys",
build_file_proto_mode = "disable_global",
importpath = "golang.org/x/sys",
sha256 = "2588b3a645838390e341f1007f8679f5e1117b5d5ac9467ef832d148b2219a38",
strip_prefix = "golang.org/x/sys@v0.8.0",
sha256 = "3b37c87534ebabf9d1a60ef03da16805f1293408bcaf8b7cbba9d646eda07d7f",
strip_prefix = "golang.org/x/sys@v0.9.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.8.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.9.0.zip",
],
)
go_repository(
name = "org_golang_x_term",
build_file_proto_mode = "disable_global",
importpath = "golang.org/x/term",
sha256 = "1961dfea59ce531e2d6e6a3228781f5958b27c6d9d9c09932f5ffc54c4d9cdf9",
strip_prefix = "golang.org/x/term@v0.8.0",
sha256 = "b4e6d2ac97732625eee581f47fe4a2125dd8668fe285794bac1a9a1a7fd3f1e3",
strip_prefix = "golang.org/x/term@v0.9.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/term/org_golang_x_term-v0.8.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/term/org_golang_x_term-v0.9.0.zip",
],
)
go_repository(
name = "org_golang_x_text",
build_file_proto_mode = "disable_global",
importpath = "golang.org/x/text",
sha256 = "c1cbe684eaf01c053bf1232738697d1040327a5c8ad62dadfc950b585d1b4caa",
strip_prefix = "golang.org/x/text@v0.9.0",
sha256 = "53e4f1af4371e78ec717fa1a2919eb9fbfb1b24c743554cfd005ee436388cee2",
strip_prefix = "golang.org/x/text@v0.10.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/text/org_golang_x_text-v0.9.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/text/org_golang_x_text-v0.10.0.zip",
],
)
go_repository(
Expand All @@ -11314,10 +11314,10 @@ def go_deps():
patches = [
"@com_github_cockroachdb_cockroach//build/patches:org_golang_x_tools.patch",
],
sha256 = "e43c6cc63a85dc30cd1794846ae96a44e81e458e88e436474c3bbbdbef80941a",
strip_prefix = "golang.org/x/tools@v0.7.0",
sha256 = "562f25e674aab49f00a23ec1fcb46a57b0a9d27287ea9a885886c994306d9c14",
strip_prefix = "golang.org/x/tools@v0.10.0",
urls = [
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/tools/org_golang_x_tools-v0.7.0.zip",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/tools/org_golang_x_tools-v0.10.0.zip",
],
)
go_repository(
Expand Down
14 changes: 7 additions & 7 deletions build/bazelutil/distdir_files.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -1051,21 +1051,21 @@ DISTDIR_FILES = {
"https://storage.googleapis.com/cockroach-godeps/gomod/go.uber.org/zap/org_uber_go_zap-v1.19.0.zip": "6437824258873fed421b7975b8e4cafd1be80cdc15e553beaa887b499dd01420",
"https://storage.googleapis.com/cockroach-godeps/gomod/goji.io/io_goji-v2.0.2+incompatible.zip": "1ea69b28e356cb91381ce2339004fcf144ad1b268c9e3497c9ef304751ae0bb3",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/arch/org_golang_x_arch-v0.0.0-20180920145803-b19384d3c130.zip": "9f67b677a3fefc503111d9aa7df8bacd2677411b0fcb982eb1654aa6d14cc3f8",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/crypto/org_golang_x_crypto-v0.9.0.zip": "672ebc916740a040d5f5472b477e1d1898e06b0c6c0a5a820b65495bbb133e82",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/crypto/org_golang_x_crypto-v0.10.0.zip": "2e4f9b72df6f480a744483b14d6b8cbad98ff066399979ac74ff1dc5b74e9bec",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/exp/org_golang_x_exp-v0.0.0-20230626212559-97b1e661b5df.zip": "af32025a065aa599a3e5b01048602a53e2b6e3938b12d33fa2a5f057be9759fa",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/exp/typeparams/org_golang_x_exp_typeparams-v0.0.0-20221208152030-732eee02a75a.zip": "9bd73f186851c6229484f486981f608d16e2b86acbbef6f4f7cc0480a508a4a4",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/image/org_golang_x_image-v0.0.0-20210628002857-a66eb6448b8d.zip": "70cf423fad9be160a88fbf01bc1897efd888f915a6d7ba0dd41ca7085f75e06e",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/lint/org_golang_x_lint-v0.0.0-20210508222113-6edffad5e616.zip": "0a4a5ebd2b1d79e7f480cbf5a54b45a257ae1ec9d11f01688efc5c35268d4603",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/mobile/org_golang_x_mobile-v0.0.0-20190719004257-d2bd2a29d028.zip": "6b946c7da47acf3b6195336fd071bfc73d543cefab73f2d27528c5dc1dc829ec",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/mod/org_golang_x_mod-v0.11.0.zip": "364198930cc7f46ba5bb1c0987d089a557aa0b406f8efec0490744a454df00a5",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.10.0.zip": "f92f9b2655226a6d015af7a76279a11fb55678e410b851b158fc846546f80733",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.11.0.zip": "5d97db0b34367452949b1b04194b47a663cbb0852f40d119ba5d910ccc124657",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/oauth2/org_golang_x_oauth2-v0.5.0.zip": "4d9d9ce8d2f55b7d2ffb3697ed811a54606e881bb7fbbd84d3d9c42fc404ae3c",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/perf/org_golang_x_perf-v0.0.0-20230113213139-801c7ef9e5c5.zip": "bc1b902e645fdd5d210b7db8f3280833af225b131dab5842d7a6d32a676f80f5",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sync/org_golang_x_sync-v0.1.0.zip": "f510bec6009e19882d19953e7273137d34df86c65949345d72f123a255c2ecd2",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.8.0.zip": "2588b3a645838390e341f1007f8679f5e1117b5d5ac9467ef832d148b2219a38",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/term/org_golang_x_term-v0.8.0.zip": "1961dfea59ce531e2d6e6a3228781f5958b27c6d9d9c09932f5ffc54c4d9cdf9",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/text/org_golang_x_text-v0.9.0.zip": "c1cbe684eaf01c053bf1232738697d1040327a5c8ad62dadfc950b585d1b4caa",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/tools/org_golang_x_tools-v0.7.0.zip": "e43c6cc63a85dc30cd1794846ae96a44e81e458e88e436474c3bbbdbef80941a",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sync/org_golang_x_sync-v0.3.0.zip": "1870e7a196f7119d4c6edba7de9cdfc49ee13c8cb7921f3a947568171c6152e0",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.9.0.zip": "3b37c87534ebabf9d1a60ef03da16805f1293408bcaf8b7cbba9d646eda07d7f",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/term/org_golang_x_term-v0.9.0.zip": "b4e6d2ac97732625eee581f47fe4a2125dd8668fe285794bac1a9a1a7fd3f1e3",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/text/org_golang_x_text-v0.10.0.zip": "53e4f1af4371e78ec717fa1a2919eb9fbfb1b24c743554cfd005ee436388cee2",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/tools/org_golang_x_tools-v0.10.0.zip": "562f25e674aab49f00a23ec1fcb46a57b0a9d27287ea9a885886c994306d9c14",
"https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/xerrors/org_golang_x_xerrors-v0.0.0-20220907171357-04be3eba64a2.zip": "b9c481db33c4b682ba8ba348018ddbd2155bd227cc38ff9f6b4cb2b74bbc3c14",
"https://storage.googleapis.com/cockroach-godeps/gomod/gonum.org/v1/gonum/org_gonum_v1_gonum-v0.11.0.zip": "abdfee15ce7c9d2cd96b66468d3ae28d6054add4efbfc1b15fadfe3613f3d362",
"https://storage.googleapis.com/cockroach-godeps/gomod/gonum.org/v1/netlib/org_gonum_v1_netlib-v0.0.0-20190331212654-76723241ea4e.zip": "ed4dca5026c9ab5410d23bbe21c089433ca58a19bd2902311c6a91791142a687",
Expand Down
2 changes: 1 addition & 1 deletion build/teamcity/cockroach/ci/tests/local_roachtest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ source "$dir/teamcity-support.sh" # For $root
source "$dir/teamcity-bazel-support.sh" # For run_bazel

tc_start_block "Run local roachtests"
BAZEL_SUPPORT_EXTRA_DOCKER_ARGS="-e COCKROACH_DEV_LICENSE -e BUILD_VCS_NUMBER -e TC_BUILD_ID -e TC_BUILD_BRANCH" \
BAZEL_SUPPORT_EXTRA_DOCKER_ARGS="-e LITERAL_ARTIFACTS_DIR=$root/artifacts -e COCKROACH_DEV_LICENSE -e BUILD_VCS_NUMBER -e TC_BUILD_ID -e TC_BUILD_BRANCH" \
run_bazel build/teamcity/cockroach/ci/tests/local_roachtest_impl.sh
tc_end_block "Run local roachtests"
2 changes: 1 addition & 1 deletion build/teamcity/cockroach/ci/tests/local_roachtest_fips.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ source "$dir/teamcity-support.sh" # For $root
source "$dir/teamcity-bazel-support.sh" # For run_bazel

tc_start_block "Run local roachtests"
BAZEL_SUPPORT_EXTRA_DOCKER_ARGS="-e COCKROACH_DEV_LICENSE -e BUILD_VCS_NUMBER -e TC_BUILD_ID -e TC_BUILD_BRANCH" \
BAZEL_SUPPORT_EXTRA_DOCKER_ARGS="-e LITERAL_ARTIFACTS_DIR=$root/artifacts -e COCKROACH_DEV_LICENSE -e BUILD_VCS_NUMBER -e TC_BUILD_ID -e TC_BUILD_BRANCH" \
run_bazel_fips build/teamcity/cockroach/ci/tests/local_roachtest_fips_impl.sh
tc_end_block "Run local roachtests"
1 change: 1 addition & 0 deletions build/teamcity/cockroach/ci/tests/local_roachtest_impl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,5 @@ $BAZEL_BIN/pkg/cmd/roachtest/roachtest_/roachtest run acceptance kv/splits cdc/b
--cockroach "$BAZEL_BIN/pkg/cmd/cockroach-short/cockroach-short_/cockroach-short" \
--workload "$BAZEL_BIN/pkg/cmd/workload/workload_/workload" \
--artifacts /artifacts \
--artifacts-literal="${LITERAL_ARTIFACTS_DIR:-}" \
--teamcity
10 changes: 10 additions & 0 deletions build/toolchains/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@ platform(
"@platforms//os:linux",
"@platforms//cpu:x86_64",
],
exec_properties = {
"container-image": "docker://cockroachdb/bazel@sha256:2fdff6a4a2c66bf01d6ad4c6973eb4b38acdb812d07a431a0471f2b6449bb653",
"dockerReuse": "True",
"Pool": "default",
},
)

toolchain(
Expand Down Expand Up @@ -131,6 +136,11 @@ platform(
"@platforms//os:linux",
"@platforms//cpu:arm64",
],
exec_properties = {
"container-image": "docker://cockroachdb/bazel@sha256:6acc131994de3e9adcdf05ddd0956a047cb7a7e07a939a76fa9cad11af3a1a8a",
"dockerReuse": "True",
"Pool": "default",
},
)

platform(
Expand Down
5 changes: 3 additions & 2 deletions docs/generated/logformats.md
Original file line number Diff line number Diff line change
Expand Up @@ -325,8 +325,9 @@ Additionally, the following fields are conditionally present:
|-------|-------|-------------|
| `N` | `node_id` | The node ID where the event was generated, once known. Only reported for single-tenant or KV servers. |
| `x` | `cluster_id` | The cluster ID where the event was generated, once known. Only reported for single-tenant of KV servers. |
| `q` | `instance_id` | The SQL instance ID where the event was generated, once known. Only reported for multi-tenant SQL servers. |
| `T` | `tenant_id` | The SQL tenant ID where the event was generated, once known. Only reported for multi-tenant SQL servers. |
| `q` | `instance_id` | The SQL instance ID where the event was generated, once known. |
| `T` | `tenant_id` | The SQL tenant ID where the event was generated, once known. |
| `V` | `tenant_name` | The SQL virtual cluster where the event was generated, once known. |
| `tags` | `tags` | The logging context tags for the entry, if there were context tags. |
| `message` | `message` | For unstructured events, the flat text payload. |
| `event` | `event` | The logging event, if structured (see below for details). |
Expand Down
2 changes: 1 addition & 1 deletion docs/generated/settings/settings-for-tenants.txt
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ sql.stats.histogram_collection.enabled boolean true histogram collection mode te
sql.stats.histogram_samples.count integer 10000 number of rows sampled for histogram construction during table statistics collection tenant-rw
sql.stats.multi_column_collection.enabled boolean true multi-column statistics collection mode tenant-rw
sql.stats.non_default_columns.min_retention_period duration 24h0m0s minimum retention period for table statistics collected on non-default columns tenant-rw
sql.stats.persisted_rows.max integer 1000000 maximum number of rows of statement and transaction statistics that will be persisted in the system tables tenant-rw
sql.stats.persisted_rows.max integer 1000000 maximum number of rows of statement and transaction statistics that will be persisted in the system tables before compaction begins tenant-rw
sql.stats.post_events.enabled boolean false if set, an event is logged for every CREATE STATISTICS job tenant-rw
sql.stats.response.max integer 20000 the maximum number of statements and transaction stats returned in a CombinedStatements request tenant-rw
sql.stats.response.show_internal.enabled boolean false controls if statistics for internal executions should be returned by the CombinedStatements and if internal sessions should be returned by the ListSessions endpoints. These endpoints are used to display statistics on the SQL Activity pages tenant-rw
Expand Down
Loading

0 comments on commit 5d2bec4

Please sign in to comment.