Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into max-execution-time-ti…
Browse files Browse the repository at this point in the history
…meout
  • Loading branch information
timvaillancourt committed Nov 4, 2023
2 parents 63379ff + c341b32 commit 252e945
Show file tree
Hide file tree
Showing 2,425 changed files with 437,285 additions and 230,879 deletions.
18 changes: 9 additions & 9 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ go.sum @ajm188 @deepthi @harshit-gangal @mattlord @rohit-nayak-ps @systay @froui
/.github/ISSUE_TEMPLATE/ @deepthi @frouioui @mattlord
/.github/workflows/ @deepthi @frouioui @mattlord @rohit-nayak-ps
/config/mycnf/ @deepthi @shlomi-noach @mattlord
/doc/ @deepthi @frouioui @GuptaManan100 @rsajwani
/doc/ @deepthi @frouioui @GuptaManan100
/docker/ @deepthi @derekperkins @dkhenry @mattlord @GuptaManan100 @frouioui
/examples/compose @shlomi-noach @GuptaManan100 @frouioui
/examples/demo @mattlord @rohit-nayak-ps
Expand All @@ -26,21 +26,21 @@ go.sum @ajm188 @deepthi @harshit-gangal @mattlord @rohit-nayak-ps @systay @froui
/go/test/endtoend/onlineddl @rohit-nayak-ps @shlomi-noach
/go/test/endtoend/messaging @mattlord @rohit-nayak-ps @derekperkins
/go/test/endtoend/vtgate @harshit-gangal @systay @frouioui
/go/test/endtoend/vtorc @deepthi @shlomi-noach @GuptaManan100 @rsajwani
/go/test/endtoend/vtorc @deepthi @shlomi-noach @GuptaManan100
/go/tools/ @frouioui @systay
/go/vt/dbconnpool @harshit-gangal @mattlord
/go/vt/discovery @deepthi @frouioui
/go/vt/discovery/*tablet_picker* @rohit-nayak-ps @mattlord
/go/vt/mysqlctl @deepthi @mattlord @rsajwani
/go/vt/mysqlctl @deepthi @mattlord
/go/vt/proto @deepthi @harshit-gangal @mattlord
/go/vt/proto/vtadmin @ajm188 @notfelineit
/go/vt/schema @mattlord @shlomi-noach
/go/vt/servenv @deepthi @ajm188
/go/vt/sqlparser @harshit-gangal @systay @GuptaManan100
/go/vt/srvtopo @deepthi @mattlord
/go/vt/sysvars @harshit-gangal @systay
/go/vt/topo @deepthi @mattlord @rsajwani
/go/vt/topotools @deepthi @mattlord @rsajwani
/go/vt/topo @deepthi @mattlord
/go/vt/topotools @deepthi @mattlord
/go/vt/vitessdriver @harshit-gangal
/go/vt/vtadmin @ajm188 @notfelineit @rohit-nayak-ps
/go/vt/vtctl @ajm188 @deepthi @rohit-nayak-ps
Expand All @@ -56,18 +56,18 @@ go.sum @ajm188 @deepthi @harshit-gangal @mattlord @rohit-nayak-ps @systay @froui
/go/vt/vtgate/endtoend/*vstream* @rohit-nayak-ps @mattlord
/go/vt/vtgate/planbuilder @harshit-gangal @systay @frouioui @GuptaManan100 @arthurschreiber
/go/vt/vtgate/*vstream* @rohit-nayak-ps @mattlord
/go/vt/vtorc @deepthi @shlomi-noach @GuptaManan100 @rsajwani
/go/vt/vtorc @deepthi @shlomi-noach @GuptaManan100
/go/vt/vttablet/*conn* @harshit-gangal @systay
/go/vt/vttablet/endtoend @harshit-gangal @mattlord @rohit-nayak-ps @systay
/go/vt/vttablet/grpc* @ajm188 @rohit-nayak-ps @rsajwani @shlomi-noach @harshit-gangal
/go/vt/vttablet/grpc* @ajm188 @rohit-nayak-ps @shlomi-noach @harshit-gangal
/go/vt/vttablet/onlineddl @mattlord @rohit-nayak-ps @shlomi-noach
/go/vt/vttablet/queryservice @harshit-gangal @systay
/go/vt/vttablet/tabletmanager @deepthi @GuptaManan100 @rohit-nayak-ps @rsajwani @shlomi-noach
/go/vt/vttablet/tabletmanager @deepthi @GuptaManan100 @rohit-nayak-ps @shlomi-noach
/go/vt/vttablet/tabletmanager/vreplication @rohit-nayak-ps @mattlord
/go/vt/vttablet/tabletmanager/vstreamer @rohit-nayak-ps @mattlord
/go/vt/vttablet/tabletserver* @harshit-gangal @systay @shlomi-noach @rohit-nayak-ps
/go/vt/vttablet/tabletserver/messager @mattlord @rohit-nayak-ps @derekperkins
/go/vt/vttablet/*tmclient* @ajm188 @GuptaManan100 @rohit-nayak-ps @rsajwani @shlomi-noach
/go/vt/vttablet/*tmclient* @ajm188 @GuptaManan100 @rohit-nayak-ps @shlomi-noach
/go/vt/vttablet/vexec @mattlord @rohit-nayak-ps @shlomi-noach
/go/vt/wrangler @deepthi @mattlord @rohit-nayak-ps
/go/vt/workflow @mattlord @rohit-nayak-ps
Expand Down
30 changes: 30 additions & 0 deletions .github/workflows/assign_milestone.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Assign Milestone

on:
pull_request_target:
types: [opened]

permissions: read-all

env:
GH_TOKEN: ${{ github.token }}

jobs:
build:
name: Assign Milestone
runs-on: ubuntu-22.04
permissions:
pull-requests: write

steps:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.21.1

- name: Checkout code
uses: actions/checkout@v3

- name: Assign Milestone
run: |
gh pr edit ${{ github.event.number }} --milestone "v$(sed -n 's/.*versionName.*\"\([[:digit:]\.]*\).*\"/\1/p' ./go/vt/servenv/version.go)"
10 changes: 8 additions & 2 deletions .github/workflows/check_label.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ concurrency:
group: format('{0}-{1}', ${{ github.ref }}, 'Check Pull Request labels')
cancel-in-progress: true

permissions: read-all

jobs:
check_pull_request_labels:
name: Check Pull Request labels
Expand All @@ -17,7 +19,7 @@ jobs:
- name: Release Notes label
run: |
if [[ "${{contains( github.event.pull_request.labels.*.name, 'release notes (needs details)')}}" == "true" ]]; then
echo The "release notes (needs details)" label is set. The changes made in this Pull Request need to be documented in the release notes summary "('./doc/releasenotes/16_0_0_summary.md')". Once documented, the "release notes (needs details)" label can be removed.
echo The "release notes (needs details)" label is set. The changes made in this Pull Request need to be documented in the release notes summary "('./changelog/17.0/17.0.0/summary.md')". Once documented, the "release notes (needs details)" label can be removed.
exit 1
fi
Expand All @@ -42,7 +44,7 @@ jobs:
exit 1
fi
- name: Check NeedsWebsiteDocsUpdate and NeedsDescriptionUpdate are off
- name: Check all Needs labels are off
env:
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
Expand All @@ -62,6 +64,10 @@ jobs:
echo "Expecting PR to not have the NeedsWebsiteDocsUpdate label, please update the documentation and remove the label."
exit 1
fi
if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'NeedsIssue' ; then
echo "Expecting PR to not have the NeedsIssue label; please create a linked issue and remove the label."
exit 1
fi
- name: Do Not Merge label
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/check_make_vtadmin_authz_testgen.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: check_make_vtadmin_authz_testgen
on: [push, pull_request]
jobs:

permissions: read-all

jobs:
build:
name: Check Make vtadmin_authz_testgen
runs-on: ubuntu-22.04
Expand Down Expand Up @@ -45,10 +47,10 @@ jobs:
- '.github/workflows/check_make_vtadmin_authz_testgen.yml'
- name: Set up Go
uses: actions/setup-go@v3
uses: actions/setup-go@v4
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.vtadmin_changes == 'true'
with:
go-version: 1.20.1
go-version: 1.21.1

- name: Tune the OS
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.vtadmin_changes == 'true'
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/check_make_vtadmin_web_proto.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: check_make_vtadmin_web_proto
on: [push, pull_request]
jobs:

permissions: read-all

jobs:
build:
name: Check Make VTAdmin Web Proto
runs-on: ubuntu-22.04
Expand Down Expand Up @@ -47,17 +49,17 @@ jobs:
- '.github/workflows/check_make_vtadmin_web_proto.yml'
- name: Set up Go
uses: actions/setup-go@v3
uses: actions/setup-go@v4
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.proto_changes == 'true'
with:
go-version: 1.20.1
go-version: 1.21.1

- name: Setup Node
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.proto_changes == 'true'
uses: actions/setup-node@v3
with:
# node-version should match package.json
node-version: '16.19.0'
node-version: '18.16.0'

- name: Install npm dependencies
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.proto_changes == 'true'
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/close_stale_pull_requests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ on:

workflow_dispatch: {}

permissions:
pull-requests: write
permissions: read-all

jobs:
close_stale_pull_requests:
runs-on: ubuntu-22.04
permissions:
pull-requests: write

steps:
- uses: actions/stale@v5
with:
Expand Down
29 changes: 20 additions & 9 deletions .github/workflows/cluster_endtoend_12.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ concurrency:
group: format('{0}-{1}', ${{ github.ref }}, 'Cluster (12)')
cancel-in-progress: true

permissions: read-all

env:
LAUNCHABLE_ORGANIZATION: "vitess"
LAUNCHABLE_WORKSPACE: "vitess-app"
Expand All @@ -14,7 +16,7 @@ env:
jobs:
build:
name: Run endtoend tests on Cluster (12)
runs-on: ubuntu-22.04
runs-on: gh-hosted-runners-4cores-1

steps:
- name: Skip CI
Expand All @@ -34,6 +36,13 @@ jobs:
echo Skip ${skip}
echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT
PR_DATA=$(curl \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
"https://api.github.com/repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}")
draft=$(echo "$PR_DATA" | jq .draft -r)
echo "is_draft=${draft}" >> $GITHUB_OUTPUT
- name: Check out code
if: steps.skip-workflow.outputs.skip-workflow == 'false'
uses: actions/checkout@v3
Expand All @@ -60,9 +69,9 @@ jobs:
- name: Set up Go
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
uses: actions/setup-go@v3
uses: actions/setup-go@v4
with:
go-version: 1.20.1
go-version: 1.21.1

- name: Set up python
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
Expand Down Expand Up @@ -102,7 +111,7 @@ jobs:
go install github.com/vitessio/go-junit-report@HEAD
- name: Setup launchable dependencies
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
if: steps.skip-workflow.outputs.is_draft == 'false' && steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' && github.base_ref == 'main'
run: |
# Get Launchable CLI installed. If you can, make it a part of the builder image to speed things up
pip3 install --user launchable~=1.0 > /dev/null
Expand All @@ -111,7 +120,7 @@ jobs:
launchable verify || true
# Tell Launchable about the build you are producing and testing
launchable record build --name "$GITHUB_RUN_ID" --source .
launchable record build --name "$GITHUB_RUN_ID" --no-commit-collection --source .
- name: Run cluster endtoend test
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
Expand All @@ -122,16 +131,18 @@ jobs:
export VTDATAROOT="/tmp/"
source build.env
set -x
set -exo pipefail
# run the tests however you normally do, then produce a JUnit XML file
eatmydata -- go run test.go -docker=false -follow -shard 12 | tee -a output.txt | go-junit-report -set-exit-code > report.xml
- name: Print test output and Record test result in launchable
- name: Print test output and Record test result in launchable if PR is not a draft
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' && always()
run: |
# send recorded tests to launchable
launchable record tests --build "$GITHUB_RUN_ID" go-test . || true
if [[ "${{steps.skip-workflow.outputs.is_draft}}" == "false" ]]; then
# send recorded tests to launchable
launchable record tests --build "$GITHUB_RUN_ID" go-test . || true
fi
# print test output
cat output.txt
29 changes: 20 additions & 9 deletions .github/workflows/cluster_endtoend_13.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ concurrency:
group: format('{0}-{1}', ${{ github.ref }}, 'Cluster (13)')
cancel-in-progress: true

permissions: read-all

env:
LAUNCHABLE_ORGANIZATION: "vitess"
LAUNCHABLE_WORKSPACE: "vitess-app"
Expand All @@ -14,7 +16,7 @@ env:
jobs:
build:
name: Run endtoend tests on Cluster (13)
runs-on: ubuntu-22.04
runs-on: gh-hosted-runners-4cores-1

steps:
- name: Skip CI
Expand All @@ -34,6 +36,13 @@ jobs:
echo Skip ${skip}
echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT
PR_DATA=$(curl \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
"https://api.github.com/repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}")
draft=$(echo "$PR_DATA" | jq .draft -r)
echo "is_draft=${draft}" >> $GITHUB_OUTPUT
- name: Check out code
if: steps.skip-workflow.outputs.skip-workflow == 'false'
uses: actions/checkout@v3
Expand All @@ -60,9 +69,9 @@ jobs:
- name: Set up Go
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
uses: actions/setup-go@v3
uses: actions/setup-go@v4
with:
go-version: 1.20.1
go-version: 1.21.1

- name: Set up python
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
Expand Down Expand Up @@ -102,7 +111,7 @@ jobs:
go install github.com/vitessio/go-junit-report@HEAD
- name: Setup launchable dependencies
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
if: steps.skip-workflow.outputs.is_draft == 'false' && steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' && github.base_ref == 'main'
run: |
# Get Launchable CLI installed. If you can, make it a part of the builder image to speed things up
pip3 install --user launchable~=1.0 > /dev/null
Expand All @@ -111,7 +120,7 @@ jobs:
launchable verify || true
# Tell Launchable about the build you are producing and testing
launchable record build --name "$GITHUB_RUN_ID" --source .
launchable record build --name "$GITHUB_RUN_ID" --no-commit-collection --source .
- name: Run cluster endtoend test
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true'
Expand All @@ -122,16 +131,18 @@ jobs:
export VTDATAROOT="/tmp/"
source build.env
set -x
set -exo pipefail
# run the tests however you normally do, then produce a JUnit XML file
eatmydata -- go run test.go -docker=false -follow -shard 13 | tee -a output.txt | go-junit-report -set-exit-code > report.xml
- name: Print test output and Record test result in launchable
- name: Print test output and Record test result in launchable if PR is not a draft
if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' && always()
run: |
# send recorded tests to launchable
launchable record tests --build "$GITHUB_RUN_ID" go-test . || true
if [[ "${{steps.skip-workflow.outputs.is_draft}}" == "false" ]]; then
# send recorded tests to launchable
launchable record tests --build "$GITHUB_RUN_ID" go-test . || true
fi
# print test output
cat output.txt
Loading

0 comments on commit 252e945

Please sign in to comment.