-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
77864: roachtest: add pebble ycsb/A race build roachtest r=bananabrick a=bananabrick Release note: None 78586: sql: regression test for MVCC timestamp in materialized views r=dt a=rafiss refs #62932 Before abeaf01 this test would have failed, so this test will help make sure we don't regress. Release note: None 79048: sql: Node user always passes CheckAnyPrivilege r=rafiss a=RichardJCai No release note since this only affects what is shown in InternalExecutor queries. Release note: None 79055: sql: use qualifiable schema name for comment on schema r=chengxiong-ruan a=chengxiong-ruan Previously we only use current db to resolve a schema when comment on a schema. This is painful at least for our testing sometimes because we need to switch db before commenting on a schema. Release justification: low impact but can be useful for users. Release note (sql change): `COMMENT ON SCHEMA` now can use qualified schema name. So can do both `COMMENT ON SCHEMA sc_name ...` and `COMMENT ON SCHEMA db_name.sc_name ...`. 79068: dev: copy built binaries rather than symlinking them r=mari-crl a=rickystewart This uses more disk space but is resilient to the confusing case where your Bazel `output_base` gets deleted (either due to `bazel clean --expunge` or if your `output_base` gets wiped due to a macOS upgrade). Release note: None Co-authored-by: Arjun Nair <[email protected]> Co-authored-by: Rafi Shamim <[email protected]> Co-authored-by: richardjcai <[email protected]> Co-authored-by: Chengxiong Ruan <[email protected]> Co-authored-by: Ricky Stewart <[email protected]>
- Loading branch information
Showing
17 changed files
with
286 additions
and
58 deletions.
There are no files selected for viewing
53 changes: 53 additions & 0 deletions
53
build/teamcity/cockroach/nightlies/pebble_nightly_race_common.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
#!/usr/bin/env bash | ||
# | ||
# This script contains common configuration used by the Pebble Nightly race runs. | ||
|
||
set -euo pipefail | ||
|
||
if [[ "$GOOGLE_EPHEMERAL_CREDENTIALS" ]]; then | ||
echo "$GOOGLE_EPHEMERAL_CREDENTIALS" > creds.json | ||
gcloud auth activate-service-account --key-file=creds.json | ||
export ROACHPROD_USER=teamcity | ||
else | ||
echo 'warning: GOOGLE_EPHEMERAL_CREDENTIALS not set' >&2 | ||
echo "Assuming that you've run \`gcloud auth login\` from inside the builder." >&2 | ||
fi | ||
|
||
set -ux | ||
|
||
if [[ ! -f ~/.ssh/id_rsa.pub ]]; then | ||
ssh-keygen -q -N "" -f ~/.ssh/id_rsa | ||
fi | ||
|
||
# The artifacts dir should match up with that supplied by TC. | ||
artifacts=$PWD/artifacts | ||
mkdir -p "${artifacts}" | ||
chmod o+rwx "${artifacts}" | ||
mkdir -p "$PWD/bin" | ||
chmod o+rwx "$PWD/bin" | ||
|
||
build_tag=$(git describe --abbrev=0 --tags --match=v[0-9]*) | ||
export build_tag | ||
|
||
# Build the roachtest binary. | ||
bazel build //pkg/cmd/roachtest --config ci -c opt | ||
BAZEL_BIN=$(bazel info bazel-bin --config ci -c opt) | ||
cp $BAZEL_BIN/pkg/cmd/roachtest/roachtest_/roachtest bin | ||
chmod a+w bin/roachtest | ||
|
||
# Pull in the latest version of Pebble from upstream. The benchmarks run | ||
# against the tip of the 'master' branch. We do this by `go get`ting the | ||
# latest version of the module, and then running `mirror` to update `DEPS.bzl` | ||
# accordingly. | ||
bazel run @go_sdk//:bin/go get github.com/cockroachdb/pebble@latest | ||
NEW_DEPS_BZL_CONTENT=$(bazel run //pkg/cmd/mirror) | ||
echo "$NEW_DEPS_BZL_CONTENT" > DEPS.bzl | ||
bazel build @com_github_cockroachdb_pebble//cmd/pebble --config race --config ci -c opt | ||
BAZEL_BIN=$(bazel info bazel-bin --config race --config ci -c opt) | ||
cp $BAZEL_BIN/external/com_github_cockroachdb_pebble/cmd/pebble/pebble_/pebble ./pebble.linux | ||
chmod a+w ./pebble.linux | ||
|
||
# Set the location of the pebble binary. This is referenced by the roachtests, | ||
# which will push this binary out to all workers in order to run the | ||
# benchmarks. | ||
export PEBBLE_BIN=pebble.linux |
18 changes: 18 additions & 0 deletions
18
build/teamcity/cockroach/nightlies/pebble_nightly_ycsb_race.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/env bash | ||
# | ||
# This script runs the Pebble Nightly YCSB A benchmark with the race flag. | ||
# It is used to detect data races which may have been introduced to the latest | ||
# Pebble master branch. | ||
# | ||
# It is run by the Pebble Nightly YCSB A race TeamCity build | ||
# configuration. | ||
|
||
set -euo pipefail | ||
|
||
dir="$(dirname $(dirname $(dirname $(dirname "${0}"))))" | ||
|
||
source "$dir/teamcity-support.sh" # For $root | ||
source "$dir/teamcity-bazel-support.sh" # For run_bazel | ||
|
||
BAZEL_SUPPORT_EXTRA_DOCKER_ARGS="-e LITERAL_ARTIFACTS_DIR=$root/artifacts -e AWS_ACCESS_KEY_ID -e AWS_SECRET_ACCESS_KEY -e GOOGLE_EPHEMERAL_CREDENTIALS -e TC_BUILD_BRANCH -e TC_BUILD_ID -e TC_SERVER_URL" \ | ||
run_bazel build/teamcity/cockroach/nightlies/pebble_nightly_ycsb_race_impl.sh |
33 changes: 33 additions & 0 deletions
33
build/teamcity/cockroach/nightlies/pebble_nightly_ycsb_race_impl.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -euo pipefail | ||
|
||
_dir="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" | ||
|
||
# Execute the common commands for the benchmark runs. | ||
. "$_dir/pebble_nightly_race_common.sh" | ||
|
||
# Run the YCSB benchmark. | ||
# | ||
# NB: We specify "true" for the --cockroach and --workload binaries to | ||
# prevent roachtest from complaining (and failing) when it can't find | ||
# them. The pebble roachtests don't actually use either cockroach or | ||
# workload. | ||
exit_status=0 | ||
if ! timeout -s INT $((1000*60)) bin/roachtest run \ | ||
--build-tag "${build_tag}" \ | ||
--slack-token "${SLACK_TOKEN-}" \ | ||
--cluster-id "${TC_BUILD_ID-$(date +"%Y%m%d%H%M%S")}" \ | ||
--cloud "aws" \ | ||
--cockroach "true" \ | ||
--workload "true" \ | ||
--artifacts "$artifacts" \ | ||
--artifacts-literal="${LITERAL_ARTIFACTS_DIR:-}" \ | ||
--parallelism 3 \ | ||
--teamcity \ | ||
--cpu-quota=384 \ | ||
pebble tag:pebble_nightly_ycsb_race; then | ||
exit_status=$? | ||
fi | ||
|
||
exit "$exit_status" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.