diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 755ca395b68..34cc5186a2e 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1,82 +1 @@ -* @deepthi -bootstrap.sh @ajm188 @deepthi @frouioui @vmg -go.mod @ajm188 @deepthi @harshit-gangal @mattlord @rohit-nayak-ps @systay @frouioui -go.sum @ajm188 @deepthi @harshit-gangal @mattlord @rohit-nayak-ps @systay @frouioui -/.github/ @deepthi @mattlord @rohit-nayak-ps @frouioui -/.github/ISSUE_TEMPLATE/ @deepthi @frouioui @mattlord -/.github/workflows/ @deepthi @frouioui @mattlord @rohit-nayak-ps -/config/mycnf/ @deepthi @shlomi-noach @mattlord -/doc/ @deepthi @frouioui @GuptaManan100 -/docker/ @deepthi @derekperkins @dkhenry @mattlord @GuptaManan100 @frouioui -/examples/compose @shlomi-noach @GuptaManan100 @frouioui -/examples/demo @mattlord @rohit-nayak-ps -/examples/local @rohit-nayak-ps @frouioui @mattlord @GuptaManan100 -/examples/operator @GuptaManan100 @frouioui @mattlord -/examples/region_sharding @deepthi @mattlord -/java/ @harshit-gangal -/go/cache @vmg -/go/cmd @ajm188 @deepthi -/go/cmd/vtadmin @ajm188 @notfelineit -/go/cmd/vtctldclient @ajm188 @mattlord -/go/cmd/vtctldclient/command/vreplication @mattlord @rohit-nayak-ps -/go/internal/flag @ajm188 @rohit-nayak-ps -/go/mysql @harshit-gangal @systay @mattlord -/go/pools @deepthi @harshit-gangal -/go/protoutil @ajm188 @deepthi -/go/sqltypes @harshit-gangal @shlomi-noach @vmg -/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 -/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 -/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 -/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 -/go/vt/vtctl/vtctl.go @notfelineit @rohit-nayak-ps -/go/vt/vtctl/grpcvtctldclient @ajm188 @notfelineit -/go/vt/vtctl/grpcvtctldserver @ajm188 @notfelineit -/go/vt/vtctl/reparentutil @ajm188 @GuptaManan100 @deepthi -/go/vt/vtctl/vtctldclient @ajm188 @notfelineit -/go/vt/vtctld @ajm188 @deepthi @notfelineit @rohit-nayak-ps -/go/vt/vterrors @harshit-gangal @systay -/go/vt/vtexplain @systay @harshit-gangal -/go/vt/vtgate @harshit-gangal @systay @frouioui @GuptaManan100 -/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 -/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 @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 @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 @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 -/proto/ @deepthi @harshit-gangal -/proto/vtadmin.proto @ajm188 @notfelineit -/proto/vtctldata.proto @ajm188 @notfelineit -/proto/vtctlservice.proto @ajm188 @notfelineit -/test/ @GuptaManan100 @frouioui @rohit-nayak-ps @deepthi @mattlord @harshit-gangal -/tools/ @frouioui @rohit-nayak-ps -/web/vtadmin @ajm188 @notfelineit -/web/vtadmin/src/proto @deepthi @harshit-gangal @mattlord +* @slackhq/vitess-approvers diff --git a/.github/workflows/assign_milestone.yml b/.github/workflows/assign_milestone.yml index fd2258cbd93..443d28e80d6 100644 --- a/.github/workflows/assign_milestone.yml +++ b/.github/workflows/assign_milestone.yml @@ -20,7 +20,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Checkout code uses: actions/checkout@v4 diff --git a/.github/workflows/auto_approve_pr.yml b/.github/workflows/auto_approve_pr.yml deleted file mode 100644 index 6985f78e224..00000000000 --- a/.github/workflows/auto_approve_pr.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: Auto Approval of Bot Pull Requests -on: - pull_request: - types: [opened, reopened] - -permissions: - contents: read - -jobs: - auto_approve: - name: Auto Approve Pull Request - runs-on: ubuntu-latest - - permissions: - pull-requests: write # only given on local PRs, forks run with `read` access - - steps: - - name: Checkout code - uses: actions/checkout@v4 - - name: Auto Approve Pull Request - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - # here we are checking that the PR has been created by the vitess-bot[bot] account and that it is not a draft - # if there is a merge conflict in the backport, the PR will always be created as a draft, meaning we can rely - # on checking whether or not the PR is a draft - if [[ "${{github.event.pull_request.user.login}}" == "vitess-bot[bot]" ]] && [[ "${{github.event.pull_request.draft}}" == "false" ]]; then - gh pr review ${{ github.event.pull_request.number }} --approve - fi diff --git a/.github/workflows/check_label.yml b/.github/workflows/check_label.yml deleted file mode 100644 index ec5309c6757..00000000000 --- a/.github/workflows/check_label.yml +++ /dev/null @@ -1,80 +0,0 @@ -name: Check Pull Request labels -on: - pull_request: - types: [opened, labeled, unlabeled, synchronize] - -permissions: read-all - -jobs: - check_pull_request_labels: - name: Check Pull Request labels - timeout-minutes: 10 - runs-on: ubuntu-22.04 - if: github.repository == 'vitessio/vitess' - steps: - - 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 "('./changelog/17.0/17.0.0/summary.md')". Once documented, the "release notes (needs details)" label can be removed. - exit 1 - fi - - - name: Check type and component labels - env: - PR_NUMBER: ${{ github.event.pull_request.number }} - run: | - LABELS_JSON="/tmp/labels.json" - # Get labels for this pull request - curl -s \ - -H 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \ - -H "Accept: application/vnd.github.v3+json" \ - -H "Content-type: application/json" \ - "https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${PR_NUMBER}/labels" \ - > "$LABELS_JSON" - if ! cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'Component:' ; then - echo "Expecting PR to have label 'Component: ...'" - exit 1 - fi - if ! cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'Type:' ; then - echo "Expecting PR to have label 'Type: ...'" - exit 1 - fi - - - name: Check all Needs labels are off - env: - PR_NUMBER: ${{ github.event.pull_request.number }} - run: | - LABELS_JSON="/tmp/labels.json" - # Get labels for this pull request - curl -s \ - -H 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \ - -H "Accept: application/vnd.github.v3+json" \ - -H "Content-type: application/json" \ - "https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${PR_NUMBER}/labels" \ - > "$LABELS_JSON" - if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'NeedsDescriptionUpdate' ; then - echo "Expecting PR to not have the NeedsDescriptionUpdate label, please update the PR's description and remove the label." - exit 1 - fi - if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'NeedsWebsiteDocsUpdate' ; then - 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 - if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'NeedsBackportReason' ; then - if cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'Backport to:'; then - echo "Expecting PR to not have the NeedsBackportReason label; please add your justification to the PR description and remove the label." - exit 1 - fi - fi - - - - name: Do Not Merge label - run: | - if [[ "${{contains( github.event.pull_request.labels.*.name, 'Do Not Merge')}}" == "true" ]]; then - echo "This PR should not be merged. The 'Do Not Merge' label is set. Please unset it if you wish to merge this PR." - exit 1 - fi \ No newline at end of file diff --git a/.github/workflows/check_make_vtadmin_authz_testgen.yml b/.github/workflows/check_make_vtadmin_authz_testgen.yml index dd6608f766a..b0dc2e8305b 100644 --- a/.github/workflows/check_make_vtadmin_authz_testgen.yml +++ b/.github/workflows/check_make_vtadmin_authz_testgen.yml @@ -19,9 +19,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -50,7 +47,7 @@ jobs: uses: actions/setup-go@v5 if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.vtadmin_changes == 'true' with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.vtadmin_changes == 'true' diff --git a/.github/workflows/check_make_vtadmin_web_proto.yml b/.github/workflows/check_make_vtadmin_web_proto.yml index 8525651f55b..30aebd0b1fb 100644 --- a/.github/workflows/check_make_vtadmin_web_proto.yml +++ b/.github/workflows/check_make_vtadmin_web_proto.yml @@ -19,9 +19,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -52,7 +49,7 @@ jobs: uses: actions/setup-go@v5 if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.proto_changes == 'true' with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Setup Node if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.proto_changes == 'true' diff --git a/.github/workflows/cluster_endtoend_12.yml b/.github/workflows/cluster_endtoend_12.yml index 2b55002b65e..658f5189297 100644 --- a/.github/workflows/cluster_endtoend_12.yml +++ b/.github/workflows/cluster_endtoend_12.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (12) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_13.yml b/.github/workflows/cluster_endtoend_13.yml index d5956fe2b8e..b53b6ba364c 100644 --- a/.github/workflows/cluster_endtoend_13.yml +++ b/.github/workflows/cluster_endtoend_13.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (13) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_15.yml b/.github/workflows/cluster_endtoend_15.yml index b39b5a76953..3782182d034 100644 --- a/.github/workflows/cluster_endtoend_15.yml +++ b/.github/workflows/cluster_endtoend_15.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (15) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_18.yml b/.github/workflows/cluster_endtoend_18.yml index ede5b36ca89..6aa23610c8e 100644 --- a/.github/workflows/cluster_endtoend_18.yml +++ b/.github/workflows/cluster_endtoend_18.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (18) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_21.yml b/.github/workflows/cluster_endtoend_21.yml index bca79b4558d..e6bbfcee94b 100644 --- a/.github/workflows/cluster_endtoend_21.yml +++ b/.github/workflows/cluster_endtoend_21.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (21) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_22.yml b/.github/workflows/cluster_endtoend_22.yml index 2dbbdfb84d8..c42c9c807c2 100644 --- a/.github/workflows/cluster_endtoend_22.yml +++ b/.github/workflows/cluster_endtoend_22.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (22) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_backup_pitr.yml b/.github/workflows/cluster_endtoend_backup_pitr.yml index fa705aa650c..3b0cfff69fb 100644 --- a/.github/workflows/cluster_endtoend_backup_pitr.yml +++ b/.github/workflows/cluster_endtoend_backup_pitr.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (backup_pitr) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_backup_pitr_mysql57.yml b/.github/workflows/cluster_endtoend_backup_pitr_mysql57.yml index 5ab97490809..242a4431290 100644 --- a/.github/workflows/cluster_endtoend_backup_pitr_mysql57.yml +++ b/.github/workflows/cluster_endtoend_backup_pitr_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (backup_pitr) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup.yml b/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup.yml index de52360fabb..c5a7cbb40b8 100644 --- a/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup.yml +++ b/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (backup_pitr_xtrabackup) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup_mysql57.yml b/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup_mysql57.yml index 0b89c5f5ebb..743401bc6c1 100644 --- a/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup_mysql57.yml +++ b/.github/workflows/cluster_endtoend_backup_pitr_xtrabackup_mysql57.yml @@ -20,7 +20,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (backup_pitr_xtrabackup) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -34,9 +35,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -77,7 +75,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -130,6 +128,7 @@ jobs: wget "https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb" sudo apt-get install -y gnupg2 sudo dpkg -i "percona-release_latest.$(lsb_release -sc)_all.deb" + sudo percona-release enable-only pxb-24 sudo apt-get update if [[ -n $XTRABACKUP_VERSION ]]; then debfile="percona-xtrabackup-24_$XTRABACKUP_VERSION.$(lsb_release -sc)_amd64.deb" diff --git a/.github/workflows/cluster_endtoend_ers_prs_newfeatures_heavy.yml b/.github/workflows/cluster_endtoend_ers_prs_newfeatures_heavy.yml index e6c0554eb18..71c85faf1b7 100644 --- a/.github/workflows/cluster_endtoend_ers_prs_newfeatures_heavy.yml +++ b/.github/workflows/cluster_endtoend_ers_prs_newfeatures_heavy.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (ers_prs_newfeatures_heavy) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_mysql80.yml b/.github/workflows/cluster_endtoend_mysql80.yml index 0a97a9031e9..2543d85324a 100644 --- a/.github/workflows/cluster_endtoend_mysql80.yml +++ b/.github/workflows/cluster_endtoend_mysql80.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (mysql80) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_mysql_server_vault.yml b/.github/workflows/cluster_endtoend_mysql_server_vault.yml index c8406b31d61..324d8b7c494 100644 --- a/.github/workflows/cluster_endtoend_mysql_server_vault.yml +++ b/.github/workflows/cluster_endtoend_mysql_server_vault.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (mysql_server_vault) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_ghost.yml b/.github/workflows/cluster_endtoend_onlineddl_ghost.yml index 61b8569e352..bc7ac4d74eb 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_ghost.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_ghost.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_ghost) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_ghost_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_ghost_mysql57.yml index b067cc473a3..a3d69514f50 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_ghost_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_ghost_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_ghost) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_revert.yml b/.github/workflows/cluster_endtoend_onlineddl_revert.yml index e07cfc0c09a..5810d4dd577 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_revert.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_revert.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_revert) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_revert_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_revert_mysql57.yml index fc887a63089..688384a0b5d 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_revert_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_revert_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_revert) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_scheduler.yml b/.github/workflows/cluster_endtoend_onlineddl_scheduler.yml index 8e6e2614026..d59140c1f9e 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_scheduler.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_scheduler.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_scheduler) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_scheduler_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_scheduler_mysql57.yml index 9e1a9509c14..f69b2db0b84 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_scheduler_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_scheduler_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_scheduler) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl.yml index 56a2c39116b..55789254b23 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_mysql57.yml index e6e5b7c1f6d..64d24b706ed 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl) mysql57 - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress.yml index d5c36881728..739b967fe14 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl_stress) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_mysql57.yml index d4dff140d19..592ecbcfb92 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl_stress) mysql57 - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite.yml index a582acc96fb..f612a115703 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl_stress_suite) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite_mysql57.yml index fa69af42c8b..8a548d1ac61 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl_stress_suite) mysql57 - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite.yml index 7168fa5951a..e7070e27e97 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl_suite) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite_mysql57.yml b/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite_mysql57.yml index 7dd0ba51901..4c21b637ee5 100644 --- a/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite_mysql57.yml +++ b/.github/workflows/cluster_endtoend_onlineddl_vrepl_suite_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (onlineddl_vrepl_suite) mysql57 - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_schemadiff_vrepl.yml b/.github/workflows/cluster_endtoend_schemadiff_vrepl.yml index 8387578b380..f8f941c16b3 100644 --- a/.github/workflows/cluster_endtoend_schemadiff_vrepl.yml +++ b/.github/workflows/cluster_endtoend_schemadiff_vrepl.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (schemadiff_vrepl) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_schemadiff_vrepl_mysql57.yml b/.github/workflows/cluster_endtoend_schemadiff_vrepl_mysql57.yml index 8a1c332bdb3..5ae49a81bcf 100644 --- a/.github/workflows/cluster_endtoend_schemadiff_vrepl_mysql57.yml +++ b/.github/workflows/cluster_endtoend_schemadiff_vrepl_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (schemadiff_vrepl) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_tabletmanager_consul.yml b/.github/workflows/cluster_endtoend_tabletmanager_consul.yml index 28ca6dc23c7..68dc8bed1fb 100644 --- a/.github/workflows/cluster_endtoend_tabletmanager_consul.yml +++ b/.github/workflows/cluster_endtoend_tabletmanager_consul.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (tabletmanager_consul) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_tabletmanager_tablegc.yml b/.github/workflows/cluster_endtoend_tabletmanager_tablegc.yml index 455d5b0e691..75f75b8271c 100644 --- a/.github/workflows/cluster_endtoend_tabletmanager_tablegc.yml +++ b/.github/workflows/cluster_endtoend_tabletmanager_tablegc.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (tabletmanager_tablegc) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_tabletmanager_tablegc_mysql57.yml b/.github/workflows/cluster_endtoend_tabletmanager_tablegc_mysql57.yml index 84ca90413f7..e97e7893aa1 100644 --- a/.github/workflows/cluster_endtoend_tabletmanager_tablegc_mysql57.yml +++ b/.github/workflows/cluster_endtoend_tabletmanager_tablegc_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (tabletmanager_tablegc) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_tabletmanager_throttler_topo.yml b/.github/workflows/cluster_endtoend_tabletmanager_throttler_topo.yml index 298b28d809d..5ddf42eecea 100644 --- a/.github/workflows/cluster_endtoend_tabletmanager_throttler_topo.yml +++ b/.github/workflows/cluster_endtoend_tabletmanager_throttler_topo.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (tabletmanager_throttler_topo) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_topo_connection_cache.yml b/.github/workflows/cluster_endtoend_topo_connection_cache.yml index 4c9e6d90a25..3c06780253f 100644 --- a/.github/workflows/cluster_endtoend_topo_connection_cache.yml +++ b/.github/workflows/cluster_endtoend_topo_connection_cache.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (topo_connection_cache) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_across_db_versions.yml b/.github/workflows/cluster_endtoend_vreplication_across_db_versions.yml index ff0109ae189..6fbbd050310 100644 --- a/.github/workflows/cluster_endtoend_vreplication_across_db_versions.yml +++ b/.github/workflows/cluster_endtoend_vreplication_across_db_versions.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_across_db_versions) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_basic.yml b/.github/workflows/cluster_endtoend_vreplication_basic.yml index 10651c9954d..a3ae90d4279 100644 --- a/.github/workflows/cluster_endtoend_vreplication_basic.yml +++ b/.github/workflows/cluster_endtoend_vreplication_basic.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_basic) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_cellalias.yml b/.github/workflows/cluster_endtoend_vreplication_cellalias.yml index c7288eaf4e3..cd700eed6e4 100644 --- a/.github/workflows/cluster_endtoend_vreplication_cellalias.yml +++ b/.github/workflows/cluster_endtoend_vreplication_cellalias.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_cellalias) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_foreign_key_stress.yml b/.github/workflows/cluster_endtoend_vreplication_foreign_key_stress.yml index ddb500dce7a..912515c550d 100644 --- a/.github/workflows/cluster_endtoend_vreplication_foreign_key_stress.yml +++ b/.github/workflows/cluster_endtoend_vreplication_foreign_key_stress.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_foreign_key_stress) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_migrate_vdiff2_convert_tz.yml b/.github/workflows/cluster_endtoend_vreplication_migrate_vdiff2_convert_tz.yml index 070d107826a..5cd6d6fe216 100644 --- a/.github/workflows/cluster_endtoend_vreplication_migrate_vdiff2_convert_tz.yml +++ b/.github/workflows/cluster_endtoend_vreplication_migrate_vdiff2_convert_tz.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_migrate_vdiff2_convert_tz) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_partial_movetables_and_materialize.yml b/.github/workflows/cluster_endtoend_vreplication_partial_movetables_and_materialize.yml index f6df1a56112..0ec0a6d5a72 100644 --- a/.github/workflows/cluster_endtoend_vreplication_partial_movetables_and_materialize.yml +++ b/.github/workflows/cluster_endtoend_vreplication_partial_movetables_and_materialize.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_partial_movetables_and_materialize) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vreplication_v2.yml b/.github/workflows/cluster_endtoend_vreplication_v2.yml index a08013320c5..376eb2ac38d 100644 --- a/.github/workflows/cluster_endtoend_vreplication_v2.yml +++ b/.github/workflows/cluster_endtoend_vreplication_v2.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vreplication_v2) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vstream.yml b/.github/workflows/cluster_endtoend_vstream.yml index 9b9c84c8b07..fe9681d6b28 100644 --- a/.github/workflows/cluster_endtoend_vstream.yml +++ b/.github/workflows/cluster_endtoend_vstream.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vstream) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtbackup.yml b/.github/workflows/cluster_endtoend_vtbackup.yml index 1807915b32d..e5fddd4289f 100644 --- a/.github/workflows/cluster_endtoend_vtbackup.yml +++ b/.github/workflows/cluster_endtoend_vtbackup.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtbackup) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtctlbackup_sharded_clustertest_heavy.yml b/.github/workflows/cluster_endtoend_vtctlbackup_sharded_clustertest_heavy.yml index 5bbfb0ff06d..7742238b583 100644 --- a/.github/workflows/cluster_endtoend_vtctlbackup_sharded_clustertest_heavy.yml +++ b/.github/workflows/cluster_endtoend_vtctlbackup_sharded_clustertest_heavy.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtctlbackup_sharded_clustertest_heavy) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_concurrentdml.yml b/.github/workflows/cluster_endtoend_vtgate_concurrentdml.yml index 3776278aad4..af3bcfd1bb5 100644 --- a/.github/workflows/cluster_endtoend_vtgate_concurrentdml.yml +++ b/.github/workflows/cluster_endtoend_vtgate_concurrentdml.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_concurrentdml) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_foreignkey_stress.yml b/.github/workflows/cluster_endtoend_vtgate_foreignkey_stress.yml index 352fa5a8d3c..22dd904d774 100644 --- a/.github/workflows/cluster_endtoend_vtgate_foreignkey_stress.yml +++ b/.github/workflows/cluster_endtoend_vtgate_foreignkey_stress.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_foreignkey_stress) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_gen4.yml b/.github/workflows/cluster_endtoend_vtgate_gen4.yml index b1249777ee2..8217c502250 100644 --- a/.github/workflows/cluster_endtoend_vtgate_gen4.yml +++ b/.github/workflows/cluster_endtoend_vtgate_gen4.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_gen4) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_general_heavy.yml b/.github/workflows/cluster_endtoend_vtgate_general_heavy.yml index 9524e7b2085..ab89f3dfe1d 100644 --- a/.github/workflows/cluster_endtoend_vtgate_general_heavy.yml +++ b/.github/workflows/cluster_endtoend_vtgate_general_heavy.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_general_heavy) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_godriver.yml b/.github/workflows/cluster_endtoend_vtgate_godriver.yml index b6f52b9364c..da3b32b43cd 100644 --- a/.github/workflows/cluster_endtoend_vtgate_godriver.yml +++ b/.github/workflows/cluster_endtoend_vtgate_godriver.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_godriver) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_partial_keyspace.yml b/.github/workflows/cluster_endtoend_vtgate_partial_keyspace.yml index 7f9000a9d07..415135761f8 100644 --- a/.github/workflows/cluster_endtoend_vtgate_partial_keyspace.yml +++ b/.github/workflows/cluster_endtoend_vtgate_partial_keyspace.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_partial_keyspace) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_queries.yml b/.github/workflows/cluster_endtoend_vtgate_queries.yml index 5ce4452cc00..2f84ea069a6 100644 --- a/.github/workflows/cluster_endtoend_vtgate_queries.yml +++ b/.github/workflows/cluster_endtoend_vtgate_queries.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_queries) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_readafterwrite.yml b/.github/workflows/cluster_endtoend_vtgate_readafterwrite.yml index f78bdfbbce0..52a42d77414 100644 --- a/.github/workflows/cluster_endtoend_vtgate_readafterwrite.yml +++ b/.github/workflows/cluster_endtoend_vtgate_readafterwrite.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_readafterwrite) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_reservedconn.yml b/.github/workflows/cluster_endtoend_vtgate_reservedconn.yml index a5435c68dc4..45283ba4fba 100644 --- a/.github/workflows/cluster_endtoend_vtgate_reservedconn.yml +++ b/.github/workflows/cluster_endtoend_vtgate_reservedconn.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_reservedconn) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_schema.yml b/.github/workflows/cluster_endtoend_vtgate_schema.yml index 532b966ff7c..ce81d8ab02c 100644 --- a/.github/workflows/cluster_endtoend_vtgate_schema.yml +++ b/.github/workflows/cluster_endtoend_vtgate_schema.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_schema) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_schema_tracker.yml b/.github/workflows/cluster_endtoend_vtgate_schema_tracker.yml index 678a2dad30e..26090d44806 100644 --- a/.github/workflows/cluster_endtoend_vtgate_schema_tracker.yml +++ b/.github/workflows/cluster_endtoend_vtgate_schema_tracker.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_schema_tracker) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_tablet_healthcheck_cache.yml b/.github/workflows/cluster_endtoend_vtgate_tablet_healthcheck_cache.yml index 889575a4f36..504d9932be2 100644 --- a/.github/workflows/cluster_endtoend_vtgate_tablet_healthcheck_cache.yml +++ b/.github/workflows/cluster_endtoend_vtgate_tablet_healthcheck_cache.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_tablet_healthcheck_cache) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_topo.yml b/.github/workflows/cluster_endtoend_vtgate_topo.yml index 2514e87b31e..adb1f2e10e2 100644 --- a/.github/workflows/cluster_endtoend_vtgate_topo.yml +++ b/.github/workflows/cluster_endtoend_vtgate_topo.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_topo) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_topo_consul.yml b/.github/workflows/cluster_endtoend_vtgate_topo_consul.yml index d5c920e8d51..ac924cf7141 100644 --- a/.github/workflows/cluster_endtoend_vtgate_topo_consul.yml +++ b/.github/workflows/cluster_endtoend_vtgate_topo_consul.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_topo_consul) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_topo_etcd.yml b/.github/workflows/cluster_endtoend_vtgate_topo_etcd.yml index fd039aa52bb..ce3215944f3 100644 --- a/.github/workflows/cluster_endtoend_vtgate_topo_etcd.yml +++ b/.github/workflows/cluster_endtoend_vtgate_topo_etcd.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_topo_etcd) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_transaction.yml b/.github/workflows/cluster_endtoend_vtgate_transaction.yml index 8d96a1d72fa..e3944dc1054 100644 --- a/.github/workflows/cluster_endtoend_vtgate_transaction.yml +++ b/.github/workflows/cluster_endtoend_vtgate_transaction.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_transaction) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_unsharded.yml b/.github/workflows/cluster_endtoend_vtgate_unsharded.yml index 17c76758db5..6fb4deb976c 100644 --- a/.github/workflows/cluster_endtoend_vtgate_unsharded.yml +++ b/.github/workflows/cluster_endtoend_vtgate_unsharded.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_unsharded) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_vindex_heavy.yml b/.github/workflows/cluster_endtoend_vtgate_vindex_heavy.yml index 0de4f4b9015..4ccb458b087 100644 --- a/.github/workflows/cluster_endtoend_vtgate_vindex_heavy.yml +++ b/.github/workflows/cluster_endtoend_vtgate_vindex_heavy.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_vindex_heavy) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtgate_vschema.yml b/.github/workflows/cluster_endtoend_vtgate_vschema.yml index 4154b83e11e..cf18f54f23f 100644 --- a/.github/workflows/cluster_endtoend_vtgate_vschema.yml +++ b/.github/workflows/cluster_endtoend_vtgate_vschema.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtgate_vschema) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtorc.yml b/.github/workflows/cluster_endtoend_vtorc.yml index 54c2abf7dbb..b4e04bad990 100644 --- a/.github/workflows/cluster_endtoend_vtorc.yml +++ b/.github/workflows/cluster_endtoend_vtorc.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtorc) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vtorc_mysql57.yml b/.github/workflows/cluster_endtoend_vtorc_mysql57.yml index 540c30a8273..40e4b3f875a 100644 --- a/.github/workflows/cluster_endtoend_vtorc_mysql57.yml +++ b/.github/workflows/cluster_endtoend_vtorc_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vtorc) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_vttablet_prscomplex.yml b/.github/workflows/cluster_endtoend_vttablet_prscomplex.yml index 9b95f49d40a..633263e94ca 100644 --- a/.github/workflows/cluster_endtoend_vttablet_prscomplex.yml +++ b/.github/workflows/cluster_endtoend_vttablet_prscomplex.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (vttablet_prscomplex) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_xb_backup.yml b/.github/workflows/cluster_endtoend_xb_backup.yml index 96436308813..d7ac7fc4d9e 100644 --- a/.github/workflows/cluster_endtoend_xb_backup.yml +++ b/.github/workflows/cluster_endtoend_xb_backup.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (xb_backup) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_xb_backup_mysql57.yml b/.github/workflows/cluster_endtoend_xb_backup_mysql57.yml index 1d591262de6..381117b010c 100644 --- a/.github/workflows/cluster_endtoend_xb_backup_mysql57.yml +++ b/.github/workflows/cluster_endtoend_xb_backup_mysql57.yml @@ -20,7 +20,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (xb_backup) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -34,9 +35,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -77,7 +75,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -130,6 +128,7 @@ jobs: wget "https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb" sudo apt-get install -y gnupg2 sudo dpkg -i "percona-release_latest.$(lsb_release -sc)_all.deb" + sudo percona-release enable-only pxb-24 sudo apt-get update if [[ -n $XTRABACKUP_VERSION ]]; then debfile="percona-xtrabackup-24_$XTRABACKUP_VERSION.$(lsb_release -sc)_amd64.deb" diff --git a/.github/workflows/cluster_endtoend_xb_recovery.yml b/.github/workflows/cluster_endtoend_xb_recovery.yml index c11621e8995..eae397c40c0 100644 --- a/.github/workflows/cluster_endtoend_xb_recovery.yml +++ b/.github/workflows/cluster_endtoend_xb_recovery.yml @@ -16,7 +16,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (xb_recovery) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -73,7 +71,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/cluster_endtoend_xb_recovery_mysql57.yml b/.github/workflows/cluster_endtoend_xb_recovery_mysql57.yml index 08edc23e559..8ece0db406a 100644 --- a/.github/workflows/cluster_endtoend_xb_recovery_mysql57.yml +++ b/.github/workflows/cluster_endtoend_xb_recovery_mysql57.yml @@ -20,7 +20,8 @@ env: jobs: build: name: Run endtoend tests on Cluster (xb_recovery) mysql57 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -34,9 +35,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -77,7 +75,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -130,6 +128,7 @@ jobs: wget "https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb" sudo apt-get install -y gnupg2 sudo dpkg -i "percona-release_latest.$(lsb_release -sc)_all.deb" + sudo percona-release enable-only pxb-24 sudo apt-get update if [[ -n $XTRABACKUP_VERSION ]]; then debfile="percona-xtrabackup-24_$XTRABACKUP_VERSION.$(lsb_release -sc)_amd64.deb" diff --git a/.github/workflows/code_freeze.yml b/.github/workflows/code_freeze.yml deleted file mode 100644 index 5640bc01b69..00000000000 --- a/.github/workflows/code_freeze.yml +++ /dev/null @@ -1,14 +0,0 @@ -name: Code Freeze -on: - pull_request: - -permissions: read-all - -jobs: - build: - name: Code Freeze - runs-on: ubuntu-22.04 - steps: - - name: Fail if Code Freeze is enabled - run: | - exit 0 diff --git a/.github/workflows/codecov.yml b/.github/workflows/codecov.yml deleted file mode 100644 index b467bef83a1..00000000000 --- a/.github/workflows/codecov.yml +++ /dev/null @@ -1,119 +0,0 @@ -name: Code Coverage -on: [push, pull_request] -concurrency: - group: format('{0}-{1}', ${{ github.ref }}, 'Code Coverage') - cancel-in-progress: true - -permissions: read-all - -jobs: - test: - name: Code Coverage - runs-on: gh-hosted-runners-16cores-1 - - steps: - - name: Check out code - uses: actions/checkout@v4 - - - name: Check for changes in files relevant to code coverage - uses: dorny/paths-filter@v3.0.1 - id: changes - with: - token: '' - filters: | - changed_files: - - .github/workflows/codecov.yml - - 'go/**' - - go.mod - - go.sum - - Makefile - - - name: Set up Go - if: steps.changes.outputs.changed_files == 'true' - uses: actions/setup-go@v5 - with: - go-version: 1.22.3 - - - name: Set up python - if: steps.changes.outputs.changed_files == 'true' - uses: actions/setup-python@v5 - - - name: Tune the OS - if: steps.changes.outputs.changed_files == 'true' - run: | - sudo sysctl -w net.ipv4.ip_local_port_range="22768 65535" - # Increase the asynchronous non-blocking I/O. More information at https://dev.mysql.com/doc/refman/5.7/en/innodb-parameters.html#sysvar_innodb_use_native_aio - echo "fs.aio-max-nr = 1048576" | sudo tee -a /etc/sysctl.conf - sudo sysctl -p /etc/sysctl.conf - - - name: Get dependencies - if: steps.changes.outputs.changed_files == 'true' - run: | - export DEBIAN_FRONTEND="noninteractive" - sudo apt-get update - - # Uninstall any previously installed MySQL first - sudo systemctl stop apparmor - sudo DEBIAN_FRONTEND="noninteractive" apt-get remove -y --purge mysql-server mysql-client mysql-common - sudo apt-get -y autoremove - sudo apt-get -y autoclean - sudo deluser mysql - sudo rm -rf /var/lib/mysql - sudo rm -rf /etc/mysql - - # Get key to latest MySQL repo - sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A8D3785C - - # mysql80 - wget -c https://dev.mysql.com/get/mysql-apt-config_0.8.29-1_all.deb - echo mysql-apt-config mysql-apt-config/select-server select mysql-8.0 | sudo debconf-set-selections - sudo DEBIAN_FRONTEND="noninteractive" dpkg -i mysql-apt-config* - sudo apt-get update - sudo DEBIAN_FRONTEND="noninteractive" apt-get install -y mysql-server mysql-client - - sudo apt-get install -y make unzip g++ curl git wget ant openjdk-11-jdk eatmydata - sudo service mysql stop - sudo bash -c "echo '/usr/sbin/mysqld { }' > /etc/apparmor.d/usr.sbin.mysqld" # https://bugs.launchpad.net/ubuntu/+source/mariadb-10.1/+bug/1806263 - sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/ - sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld || echo "could not remove mysqld profile" - - mkdir -p dist bin - curl -L https://github.com/coreos/etcd/releases/download/v3.3.10/etcd-v3.3.10-linux-amd64.tar.gz | tar -zxC dist - mv dist/etcd-v3.3.10-linux-amd64/{etcd,etcdctl} bin/ - - go mod download - go install golang.org/x/tools/cmd/goimports@latest - - - name: Run make tools - if: steps.changes.outputs.changed_files == 'true' - run: | - make tools - - - name: Run unit tests and generate code coverage reports - if: steps.changes.outputs.changed_files == 'true' - timeout-minutes: 45 - run: | - set -exo pipefail - # We set the VTDATAROOT to the /tmp folder to reduce the file path of mysql.sock file - # which musn't be more than 107 characters long. - export VTDATAROOT="/tmp/" - - export NOVTADMINBUILD=1 - - # Exclude endtoend tests from the coverage report. - # TODO: figure out how best to include our endtoend tests in the coverage report. - rm -rf go/test/endtoend go/*/endtoend go/vt/*/endtoend go/cmd/vttestserver - - eatmydata -- make unit_test_cover - - # Restore the files we deleted as codecov tries to fix their paths. - git reset --hard HEAD - - - name: Upload coverage reports to codecov.io - if: steps.changes.outputs.changed_files == 'true' - uses: codecov/codecov-action@v4 - with: - fail_ci_if_error: true - verbose: true - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} diff --git a/.github/workflows/codeql_analysis.yml b/.github/workflows/codeql_analysis.yml index 3b109b81307..5270c01b63b 100644 --- a/.github/workflows/codeql_analysis.yml +++ b/.github/workflows/codeql_analysis.yml @@ -32,7 +32,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL @@ -78,6 +78,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/create_release.yml b/.github/workflows/create_release.yml deleted file mode 100644 index e669e49448e..00000000000 --- a/.github/workflows/create_release.yml +++ /dev/null @@ -1,52 +0,0 @@ -# This creates a {tar.gz,deb,rpm} file and uploads it to a release. -# To trigger this, create a new release.. but make sure that you publish -# it immediately and do not save it as a DRAFT. - -name: Release -on: - release: - types: [created] - -permissions: read-all - -jobs: - build: - name: Create Release - runs-on: ubuntu-22.04 - permissions: - contents: write - steps: - - - name: Set up Go - uses: actions/setup-go@v5 - with: - go-version: 1.22.3 - - - name: Setup node - uses: actions/setup-node@v4 - with: - node-version: '18.16.0' - - - name: Tune the OS - run: | - sudo sysctl -w net.ipv4.ip_local_port_range="22768 65535" - - - name: Check out code - uses: actions/checkout@v4 - - - name: Get dependencies - run: | - sudo apt-get update - sudo apt-get install -y make ruby ruby-dev - go mod download - sudo gem install fpm - - - name: Make Packages - run: | - ./tools/make-release-packages.sh - - - name: Upload Files - uses: csexton/release-asset-action@master - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - pattern: "releases/*.{tar.gz,rpm,deb}" diff --git a/.github/workflows/docker_build_base.yml b/.github/workflows/docker_build_base.yml index e40a029125a..377b1a76b79 100644 --- a/.github/workflows/docker_build_base.yml +++ b/.github/workflows/docker_build_base.yml @@ -15,7 +15,8 @@ permissions: read-all jobs: build_and_push_base: name: Build and push vitess/base Docker images - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 if: github.repository == 'vitessio/vitess' strategy: @@ -77,7 +78,8 @@ jobs: build_and_push_k8s: needs: build_and_push_base name: Build and push vitess/k8s image - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 if: github.repository == 'vitessio/vitess' strategy: @@ -170,7 +172,8 @@ jobs: build_and_push_components: needs: build_and_push_k8s name: Build and push vitess components Docker images - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 if: github.repository == 'vitessio/vitess' strategy: diff --git a/.github/workflows/docker_build_lite.yml b/.github/workflows/docker_build_lite.yml index 80cc888239b..ebac086cf91 100644 --- a/.github/workflows/docker_build_lite.yml +++ b/.github/workflows/docker_build_lite.yml @@ -15,7 +15,8 @@ permissions: read-all jobs: build_and_push: name: Build and push vitess/lite Docker images - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 if: github.repository == 'vitessio/vitess' strategy: @@ -70,4 +71,4 @@ jobs: context: . file: ${{ env.DOCKERFILE }} push: true - tags: ${{ env.DOCKER_TAG }} \ No newline at end of file + tags: ${{ env.DOCKER_TAG }} diff --git a/.github/workflows/docker_build_vttestserver.yml b/.github/workflows/docker_build_vttestserver.yml index 927e55be3e0..e597fc81413 100644 --- a/.github/workflows/docker_build_vttestserver.yml +++ b/.github/workflows/docker_build_vttestserver.yml @@ -15,7 +15,8 @@ permissions: read-all jobs: build_and_push: name: Build and push vitess/vttestserver Docker images - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 if: github.repository == 'vitessio/vitess' strategy: @@ -62,4 +63,4 @@ jobs: context: . file: ${{ env.DOCKERFILE }} push: true - tags: ${{ env.DOCKER_TAG }} \ No newline at end of file + tags: ${{ env.DOCKER_TAG }} diff --git a/.github/workflows/docker_test_cluster_10.yml b/.github/workflows/docker_test_cluster_10.yml index ec73bb8702a..912a7324479 100644 --- a/.github/workflows/docker_test_cluster_10.yml +++ b/.github/workflows/docker_test_cluster_10.yml @@ -5,7 +5,8 @@ jobs: build: name: Docker Test Cluster 10 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -19,9 +20,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip $skip echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -54,7 +52,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/docker_test_cluster_25.yml b/.github/workflows/docker_test_cluster_25.yml index 95f284c41ac..7ebe8e3cef0 100644 --- a/.github/workflows/docker_test_cluster_25.yml +++ b/.github/workflows/docker_test_cluster_25.yml @@ -5,7 +5,8 @@ jobs: build: name: Docker Test Cluster 25 - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -19,9 +20,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -54,7 +52,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/e2e_race.yml b/.github/workflows/e2e_race.yml index 6e23f1fbffc..7fa5ae58e3e 100644 --- a/.github/workflows/e2e_race.yml +++ b/.github/workflows/e2e_race.yml @@ -5,7 +5,8 @@ jobs: build: name: End-to-End Test (Race) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI run: | @@ -18,9 +19,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -52,7 +50,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/endtoend.yml b/.github/workflows/endtoend.yml index f7d974ff5b3..da0568196f0 100644 --- a/.github/workflows/endtoend.yml +++ b/.github/workflows/endtoend.yml @@ -5,7 +5,8 @@ jobs: build: name: End-to-End Test - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI run: | @@ -18,9 +19,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -52,7 +50,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/.github/workflows/local_example.yml b/.github/workflows/local_example.yml index ce783af4703..72ec3234ccc 100644 --- a/.github/workflows/local_example.yml +++ b/.github/workflows/local_example.yml @@ -5,7 +5,8 @@ jobs: build: name: Local example using ${{ matrix.topo }} on ubuntu-22.04 - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 strategy: matrix: topo: [consul,etcd,zk2] @@ -22,9 +23,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -57,7 +55,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.examples == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - uses: actions/setup-node@v4 if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.examples == 'true' diff --git a/.github/workflows/region_example.yml b/.github/workflows/region_example.yml index 8e6db9502b4..4edbaa7f7dd 100644 --- a/.github/workflows/region_example.yml +++ b/.github/workflows/region_example.yml @@ -5,7 +5,8 @@ jobs: build: name: Region Sharding example using ${{ matrix.topo }} on ubuntu-22.04 - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 strategy: matrix: topo: [etcd] @@ -22,9 +23,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -57,7 +55,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.examples == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - uses: actions/setup-node@v4 if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.examples == 'true' diff --git a/.github/workflows/static_checks_etc.yml b/.github/workflows/static_checks_etc.yml index 57853a73bc9..3bb499d4dcf 100644 --- a/.github/workflows/static_checks_etc.yml +++ b/.github/workflows/static_checks_etc.yml @@ -9,7 +9,8 @@ permissions: read-all jobs: build: name: Static Code Checks Etc - runs-on: ubuntu-22.04 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -23,9 +24,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -117,7 +115,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && (steps.changes.outputs.go_files == 'true' || steps.changes.outputs.parser_changes == 'true' || steps.changes.outputs.proto_changes == 'true') uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.go_files == 'true' diff --git a/.github/workflows/unit_race.yml b/.github/workflows/unit_race.yml index bff726c4261..5a59956afc7 100644 --- a/.github/workflows/unit_race.yml +++ b/.github/workflows/unit_race.yml @@ -10,7 +10,8 @@ jobs: build: name: Unit Test (Race) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI run: | @@ -23,9 +24,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -57,7 +55,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' diff --git a/.github/workflows/unit_test_mysql57.yml b/.github/workflows/unit_test_mysql57.yml index 23becfcb476..760e2103345 100644 --- a/.github/workflows/unit_test_mysql57.yml +++ b/.github/workflows/unit_test_mysql57.yml @@ -16,7 +16,8 @@ env: jobs: test: name: Unit Test (mysql57) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -71,7 +69,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' diff --git a/.github/workflows/unit_test_mysql80.yml b/.github/workflows/unit_test_mysql80.yml index fe6f13dcc17..0b03430911b 100644 --- a/.github/workflows/unit_test_mysql80.yml +++ b/.github/workflows/unit_test_mysql80.yml @@ -16,7 +16,8 @@ env: jobs: test: name: Unit Test (mysql80) - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -30,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -71,7 +69,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' diff --git a/.github/workflows/update_golang_dependencies.yml b/.github/workflows/update_golang_dependencies.yml index 5732e35adc5..b416c09f949 100644 --- a/.github/workflows/update_golang_dependencies.yml +++ b/.github/workflows/update_golang_dependencies.yml @@ -19,7 +19,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Check out code uses: actions/checkout@v4 diff --git a/.github/workflows/update_golang_version.yml b/.github/workflows/update_golang_version.yml index b503642749a..519fac82482 100644 --- a/.github/workflows/update_golang_version.yml +++ b/.github/workflows/update_golang_version.yml @@ -22,7 +22,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Check out code uses: actions/checkout@v4 diff --git a/.github/workflows/upgrade_downgrade_test_backups_e2e.yml b/.github/workflows/upgrade_downgrade_test_backups_e2e.yml index d26eaa5bf59..aaa3cb42f9c 100644 --- a/.github/workflows/upgrade_downgrade_test_backups_e2e.yml +++ b/.github/workflows/upgrade_downgrade_test_backups_e2e.yml @@ -13,7 +13,11 @@ jobs: upgrade_downgrade_test_e2e: timeout-minutes: 60 name: Run Upgrade Downgrade Test - Backups - E2E - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 + env: + GOPRIVATE: github.com/slackhq/vitess-addons + GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} steps: - name: Skip CI @@ -27,9 +31,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -72,7 +73,10 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 + + - name: Setup github.com/slackhq/vitess-additions access token + run: git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/ - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -100,6 +104,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_backups_e2e_next_release.yml b/.github/workflows/upgrade_downgrade_test_backups_e2e_next_release.yml index c09b3ac6636..b497d4bbea0 100644 --- a/.github/workflows/upgrade_downgrade_test_backups_e2e_next_release.yml +++ b/.github/workflows/upgrade_downgrade_test_backups_e2e_next_release.yml @@ -14,7 +14,8 @@ jobs: upgrade_downgrade_test_e2e: timeout-minutes: 60 name: Run Upgrade Downgrade Test - Backups - E2E - Next Release - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -40,9 +41,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi if [[ "${{steps.output-next-release-ref.outputs.next_release_ref}}" == "" ]]; then skip='true' fi @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -102,6 +100,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_backups_manual.yml b/.github/workflows/upgrade_downgrade_test_backups_manual.yml index 462471422db..ab5021de227 100644 --- a/.github/workflows/upgrade_downgrade_test_backups_manual.yml +++ b/.github/workflows/upgrade_downgrade_test_backups_manual.yml @@ -15,7 +15,11 @@ jobs: upgrade_downgrade_test_manual: timeout-minutes: 40 name: Run Upgrade Downgrade Test - Backups - Manual - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 + env: + GOPRIVATE: github.com/slackhq/vitess-addons + GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} steps: - name: Skip CI @@ -29,9 +33,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -76,7 +77,10 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 + + - name: Setup github.com/slackhq/vitess-additions access token + run: git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/ - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -122,6 +126,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_backups_manual_next_release.yml b/.github/workflows/upgrade_downgrade_test_backups_manual_next_release.yml index 25e4abea54f..819c1f8c0c9 100644 --- a/.github/workflows/upgrade_downgrade_test_backups_manual_next_release.yml +++ b/.github/workflows/upgrade_downgrade_test_backups_manual_next_release.yml @@ -15,7 +15,8 @@ jobs: upgrade_downgrade_test_manual: timeout-minutes: 40 name: Run Upgrade Downgrade Test - Backups - Manual - Next Release - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -42,9 +43,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi if [[ "${{steps.output-next-release-ref.outputs.next_release_ref}}" == "" ]]; then skip='true' fi @@ -77,7 +75,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -123,6 +121,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_query_serving_queries.yml b/.github/workflows/upgrade_downgrade_test_query_serving_queries.yml index 62a49f346f9..6eb117d1a2b 100644 --- a/.github/workflows/upgrade_downgrade_test_query_serving_queries.yml +++ b/.github/workflows/upgrade_downgrade_test_query_serving_queries.yml @@ -16,7 +16,11 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Query Serving (Queries) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 + env: + GOPRIVATE: github.com/slackhq/vitess-addons + GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} steps: - name: Skip CI @@ -30,9 +34,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -75,7 +76,10 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 + + - name: Setup github.com/slackhq/vitess-additions access token + run: git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/ - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -119,6 +123,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_query_serving_queries_next_release.yml b/.github/workflows/upgrade_downgrade_test_query_serving_queries_next_release.yml index 368cab2ea9e..a666e7a90fd 100644 --- a/.github/workflows/upgrade_downgrade_test_query_serving_queries_next_release.yml +++ b/.github/workflows/upgrade_downgrade_test_query_serving_queries_next_release.yml @@ -16,7 +16,8 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Query Serving (Queries) Next Release - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -42,9 +43,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi if [[ "${{steps.output-next-release-ref.outputs.next_release_ref}}" == "" ]]; then skip='true' fi @@ -76,7 +74,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -120,6 +118,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_query_serving_schema.yml b/.github/workflows/upgrade_downgrade_test_query_serving_schema.yml index fc5c763721a..73eae4acaac 100644 --- a/.github/workflows/upgrade_downgrade_test_query_serving_schema.yml +++ b/.github/workflows/upgrade_downgrade_test_query_serving_schema.yml @@ -16,7 +16,11 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Query Serving (Schema) - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 + env: + GOPRIVATE: github.com/slackhq/vitess-addons + GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} steps: - name: Skip CI @@ -30,9 +34,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -75,7 +76,10 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 + + - name: Setup github.com/slackhq/vitess-additions access token + run: git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/ - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -119,6 +123,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_query_serving_schema_next_release.yml b/.github/workflows/upgrade_downgrade_test_query_serving_schema_next_release.yml index b450b594921..6c30b4acb05 100644 --- a/.github/workflows/upgrade_downgrade_test_query_serving_schema_next_release.yml +++ b/.github/workflows/upgrade_downgrade_test_query_serving_schema_next_release.yml @@ -16,7 +16,8 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Query Serving (Schema) Next Release - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -42,9 +43,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi if [[ "${{steps.output-next-release-ref.outputs.next_release_ref}}" == "" ]]; then skip='true' fi @@ -76,7 +74,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -120,6 +118,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_reparent_new_vtctl.yml b/.github/workflows/upgrade_downgrade_test_reparent_new_vtctl.yml index f1dd0384002..e9b33cdce90 100644 --- a/.github/workflows/upgrade_downgrade_test_reparent_new_vtctl.yml +++ b/.github/workflows/upgrade_downgrade_test_reparent_new_vtctl.yml @@ -16,7 +16,8 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Reparent New Vtctl - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -42,9 +43,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi if [[ "${{steps.output-next-release-ref.outputs.next_release_ref}}" == "" ]]; then skip='true' fi @@ -76,7 +74,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -120,6 +118,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_reparent_new_vttablet.yml b/.github/workflows/upgrade_downgrade_test_reparent_new_vttablet.yml index e83c6948bba..e6b61526419 100644 --- a/.github/workflows/upgrade_downgrade_test_reparent_new_vttablet.yml +++ b/.github/workflows/upgrade_downgrade_test_reparent_new_vttablet.yml @@ -16,7 +16,8 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Reparent New VTTablet - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -42,9 +43,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi if [[ "${{steps.output-next-release-ref.outputs.next_release_ref}}" == "" ]]; then skip='true' fi @@ -76,7 +74,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -120,6 +118,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_reparent_old_vtctl.yml b/.github/workflows/upgrade_downgrade_test_reparent_old_vtctl.yml index 6c898d4bd16..8d5ee34b85e 100644 --- a/.github/workflows/upgrade_downgrade_test_reparent_old_vtctl.yml +++ b/.github/workflows/upgrade_downgrade_test_reparent_old_vtctl.yml @@ -16,7 +16,11 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Reparent Old Vtctl - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 + env: + GOPRIVATE: github.com/slackhq/vitess-addons + GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} steps: - name: Skip CI @@ -30,9 +34,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -75,7 +76,10 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 + + - name: Setup github.com/slackhq/vitess-additions access token + run: git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/ - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -119,6 +123,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/upgrade_downgrade_test_reparent_old_vttablet.yml b/.github/workflows/upgrade_downgrade_test_reparent_old_vttablet.yml index fe6a426f97a..5ce2f6ac521 100644 --- a/.github/workflows/upgrade_downgrade_test_reparent_old_vttablet.yml +++ b/.github/workflows/upgrade_downgrade_test_reparent_old_vttablet.yml @@ -16,7 +16,11 @@ jobs: upgrade_downgrade_test: name: Run Upgrade Downgrade Test - Reparent Old VTTablet - runs-on: gh-hosted-runners-16cores-1 + runs-on: + group: vitess-ubuntu20 + env: + GOPRIVATE: github.com/slackhq/vitess-addons + GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} steps: - name: Skip CI @@ -30,9 +34,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -75,7 +76,10 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 + + - name: Setup github.com/slackhq/vitess-additions access token + run: git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/ - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -119,6 +123,7 @@ jobs: wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb sudo apt-get install -y gnupg2 sudo dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb + sudo percona-release enable-only pxb-24 sudo apt-get update sudo apt-get install -y percona-xtrabackup-24 diff --git a/.github/workflows/vtadmin_web_build.yml b/.github/workflows/vtadmin_web_build.yml index 8d6dddc9d81..61cb452ec6d 100644 --- a/.github/workflows/vtadmin_web_build.yml +++ b/.github/workflows/vtadmin_web_build.yml @@ -16,7 +16,8 @@ permissions: read-all jobs: build: - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI run: | @@ -29,9 +30,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT diff --git a/.github/workflows/vtadmin_web_lint.yml b/.github/workflows/vtadmin_web_lint.yml index a7fe7927bf9..035850a3c9b 100644 --- a/.github/workflows/vtadmin_web_lint.yml +++ b/.github/workflows/vtadmin_web_lint.yml @@ -29,9 +29,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT diff --git a/.github/workflows/vtadmin_web_unit_tests.yml b/.github/workflows/vtadmin_web_unit_tests.yml index 9c0fb3e9fdc..c789e2fdc65 100644 --- a/.github/workflows/vtadmin_web_unit_tests.yml +++ b/.github/workflows/vtadmin_web_unit_tests.yml @@ -16,7 +16,8 @@ permissions: read-all jobs: unit-tests: - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI run: | @@ -29,9 +30,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "${{github.event.pull_request}}" == "" ]] && [[ "${{github.ref}}" != "refs/heads/main" ]] && [[ ! "${{github.ref}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "${{github.ref}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT diff --git a/Makefile b/Makefile index c8c47f9beae..5b84184f5a9 100644 --- a/Makefile +++ b/Makefile @@ -282,7 +282,7 @@ $(PROTO_GO_OUTS): minimaltools install_protoc-gen-go proto/*.proto # This rule builds the bootstrap images for all flavors. DOCKER_IMAGES_FOR_TEST = mysql57 mysql80 percona57 percona80 DOCKER_IMAGES = common $(DOCKER_IMAGES_FOR_TEST) -BOOTSTRAP_VERSION=27.3 +BOOTSTRAP_VERSION=27.5 ensure_bootstrap_version: find docker/ -type f -exec sed -i "s/^\(ARG bootstrap_version\)=.*/\1=${BOOTSTRAP_VERSION}/" {} \; sed -i 's/\(^.*flag.String(\"bootstrap-version\",\) *\"[^\"]\+\"/\1 \"${BOOTSTRAP_VERSION}\"/' test.go diff --git a/build.env b/build.env index 34da6721aa7..da683559425 100755 --- a/build.env +++ b/build.env @@ -17,7 +17,7 @@ source ./tools/shell_functions.inc go version >/dev/null 2>&1 || fail "Go is not installed or is not in \$PATH. See https://vitess.io/contributing/build-from-source for install instructions." -goversion_min 1.22.3 || echo "Go version reported: `go version`. Version 1.22.3+ recommended. See https://vitess.io/contributing/build-from-source for install instructions." +goversion_min 1.22.5 || echo "Go version reported: `go version`. Version 1.22.5+ recommended. See https://vitess.io/contributing/build-from-source for install instructions." mkdir -p dist mkdir -p bin @@ -47,3 +47,9 @@ ln -sf "$PWD/misc/git/pre-commit" .git/hooks/pre-commit ln -sf "$PWD/misc/git/commit-msg" .git/hooks/commit-msg git config core.hooksPath .git/hooks export EXTRA_BIN=$PWD/test/bin + +# support private github.com/slackhq/vitess-addons repo +if [[ -n "${GH_ACCESS_TOKEN}" ]]; then + export GOPRIVATE=github.com/slackhq/vitess-addons + git config --global url.https://${GH_ACCESS_TOKEN}@github.com/.insteadOf https://github.com/ +fi diff --git a/docker/base/Dockerfile b/docker/base/Dockerfile index 723ff730895..ddb987480fc 100644 --- a/docker/base/Dockerfile +++ b/docker/base/Dockerfile @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql80" FROM "${image}" diff --git a/docker/base/Dockerfile.mysql57 b/docker/base/Dockerfile.mysql57 index b6dabe8500d..13c7e175912 100644 --- a/docker/base/Dockerfile.mysql57 +++ b/docker/base/Dockerfile.mysql57 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql57" FROM "${image}" diff --git a/docker/base/Dockerfile.percona57 b/docker/base/Dockerfile.percona57 index ce5b5fe88cd..f495622064b 100644 --- a/docker/base/Dockerfile.percona57 +++ b/docker/base/Dockerfile.percona57 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-percona57" FROM "${image}" diff --git a/docker/base/Dockerfile.percona80 b/docker/base/Dockerfile.percona80 index ebf8dd7200f..3c42a29660b 100644 --- a/docker/base/Dockerfile.percona80 +++ b/docker/base/Dockerfile.percona80 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-percona80" FROM "${image}" diff --git a/docker/bootstrap/CHANGELOG.md b/docker/bootstrap/CHANGELOG.md index 17c2ed44746..d739c55b80b 100644 --- a/docker/bootstrap/CHANGELOG.md +++ b/docker/bootstrap/CHANGELOG.md @@ -120,4 +120,12 @@ List of changes between bootstrap image versions. ## [27.3] - 2024-05-07 ### Changes -- Update build to golang 1.22.3 \ No newline at end of file +- Update build to golang 1.22.3 + +## [27.4] - 2024-06-05 +### Changes +- Update build to golang 1.22.4 + +## [27.5] - 2024-07-02 +### Changes +- Update build to golang 1.22.5 diff --git a/docker/bootstrap/Dockerfile.common b/docker/bootstrap/Dockerfile.common index 6ed5c8e6b26..ac7859c0a1e 100644 --- a/docker/bootstrap/Dockerfile.common +++ b/docker/bootstrap/Dockerfile.common @@ -1,4 +1,4 @@ -FROM --platform=linux/amd64 golang:1.22.3-bullseye +FROM --platform=linux/amd64 golang:1.22.5-bullseye # Install Vitess build dependencies RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \ diff --git a/docker/lite/Dockerfile.mysql57 b/docker/lite/Dockerfile.mysql57 index 2e6f7134369..d8f38f32496 100644 --- a/docker/lite/Dockerfile.mysql57 +++ b/docker/lite/Dockerfile.mysql57 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql57" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.mysql80 b/docker/lite/Dockerfile.mysql80 index 3864bc12a83..bb73c0a8ff5 100644 --- a/docker/lite/Dockerfile.mysql80 +++ b/docker/lite/Dockerfile.mysql80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql80" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.percona57 b/docker/lite/Dockerfile.percona57 index ec0d21ccb6b..da5798bf228 100644 --- a/docker/lite/Dockerfile.percona57 +++ b/docker/lite/Dockerfile.percona57 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-percona57" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.percona80 b/docker/lite/Dockerfile.percona80 index f31aa43e94f..66478659c20 100644 --- a/docker/lite/Dockerfile.percona80 +++ b/docker/lite/Dockerfile.percona80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-percona80" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.testing b/docker/lite/Dockerfile.testing index cfd12924f47..254502a08c1 100644 --- a/docker/lite/Dockerfile.testing +++ b/docker/lite/Dockerfile.testing @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql57" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.ubi7.mysql57 b/docker/lite/Dockerfile.ubi7.mysql57 index 5ad5820b4f7..6625fe3cf53 100644 --- a/docker/lite/Dockerfile.ubi7.mysql57 +++ b/docker/lite/Dockerfile.ubi7.mysql57 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql57" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.ubi7.mysql80 b/docker/lite/Dockerfile.ubi7.mysql80 index 5f674e51495..3807e67c230 100644 --- a/docker/lite/Dockerfile.ubi7.mysql80 +++ b/docker/lite/Dockerfile.ubi7.mysql80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql80" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.ubi7.percona57 b/docker/lite/Dockerfile.ubi7.percona57 index 25b620f4935..86fa1ca2038 100644 --- a/docker/lite/Dockerfile.ubi7.percona57 +++ b/docker/lite/Dockerfile.ubi7.percona57 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-percona57" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.ubi7.percona80 b/docker/lite/Dockerfile.ubi7.percona80 index ece128b786a..aff6af97cb2 100644 --- a/docker/lite/Dockerfile.ubi7.percona80 +++ b/docker/lite/Dockerfile.ubi7.percona80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-percona80" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.ubi8.arm64.mysql80 b/docker/lite/Dockerfile.ubi8.arm64.mysql80 index 1c4715803ec..f4bde08d2b3 100644 --- a/docker/lite/Dockerfile.ubi8.arm64.mysql80 +++ b/docker/lite/Dockerfile.ubi8.arm64.mysql80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql80" FROM "${image}" AS builder diff --git a/docker/lite/Dockerfile.ubi8.mysql80 b/docker/lite/Dockerfile.ubi8.mysql80 index b2e3a7b4857..2bc5d9ddd07 100644 --- a/docker/lite/Dockerfile.ubi8.mysql80 +++ b/docker/lite/Dockerfile.ubi8.mysql80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql80" FROM "${image}" AS builder diff --git a/docker/local/Dockerfile b/docker/local/Dockerfile index e5267b0bda5..8d74247bce7 100644 --- a/docker/local/Dockerfile +++ b/docker/local/Dockerfile @@ -1,4 +1,4 @@ -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-common" FROM "${image}" diff --git a/docker/vttestserver/Dockerfile.mysql57 b/docker/vttestserver/Dockerfile.mysql57 index 4bd71d40d39..444df680f12 100644 --- a/docker/vttestserver/Dockerfile.mysql57 +++ b/docker/vttestserver/Dockerfile.mysql57 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql57" FROM "${image}" AS builder diff --git a/docker/vttestserver/Dockerfile.mysql80 b/docker/vttestserver/Dockerfile.mysql80 index 589627881ed..f6ca717180a 100644 --- a/docker/vttestserver/Dockerfile.mysql80 +++ b/docker/vttestserver/Dockerfile.mysql80 @@ -17,7 +17,7 @@ # ensure images contain the right binaries. # Use a temporary layer for the build stage. -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-mysql80" FROM "${image}" AS builder diff --git a/go.mod b/go.mod index 55766529e2a..dafc96fe585 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module vitess.io/vitess -go 1.22.3 +go 1.22.5 require ( cloud.google.com/go/storage v1.39.0 @@ -96,6 +96,7 @@ require ( github.com/bndr/gotabulate v1.1.2 github.com/gammazero/deque v0.2.1 github.com/google/safehtml v0.1.0 + github.com/hashicorp/go-cleanhttp v0.5.2 github.com/hashicorp/go-version v1.6.0 github.com/kr/pretty v0.3.1 github.com/kr/text v0.2.0 @@ -142,7 +143,6 @@ require ( github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/googleapis/gax-go/v2 v2.12.2 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect - github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/hashicorp/go-hclog v1.6.2 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-rootcerts v1.0.2 // indirect diff --git a/go/flags/endtoend/vtbackup.txt b/go/flags/endtoend/vtbackup.txt index 002f4af2831..19a7a50a9ea 100644 --- a/go/flags/endtoend/vtbackup.txt +++ b/go/flags/endtoend/vtbackup.txt @@ -213,9 +213,12 @@ Flags: --tablet_manager_grpc_key string the key to use to connect --tablet_manager_grpc_server_name string the server name to use to validate server certificate --tablet_manager_protocol string Protocol to use to make tabletmanager RPCs to vttablets. (default "grpc") + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_etcd_lease_ttl int Lease TTL for locks and leader election. The client will use KeepAlive to keep the lease going. (default 30) --topo_etcd_tls_ca string path to the ca to use to validate the server cert when connecting to the etcd topo server diff --git a/go/flags/endtoend/vtcombo.txt b/go/flags/endtoend/vtcombo.txt index 8b62d4e9edf..99142bd0b74 100644 --- a/go/flags/endtoend/vtcombo.txt +++ b/go/flags/endtoend/vtcombo.txt @@ -166,6 +166,7 @@ Flags: --grpc_server_keepalive_enforcement_policy_permit_without_stream gRPC server permit client keepalive pings even when there are no active streams (RPCs) --grpc_use_effective_callerid If set, and SSL is not used, will set the immediate caller id from the effective caller id's principal. --health_check_interval duration Interval between health checks (default 20s) + --healthcheck-dial-concurrency int Maximum concurrency of new healthcheck connections. This should be less than the golang max thread limit of 10000. (default 1024) --healthcheck_retry_delay duration health check retry delay (default 2ms) --healthcheck_timeout duration the health check timeout period (default 1m0s) --heartbeat_enable If true, vttablet records (if master) or checks (if replica) the current time of a replication heartbeat in the sidecar database's heartbeat table. The result is used to inform the serving state of the vttablet via healthchecks. @@ -351,9 +352,12 @@ Flags: --tablet_refresh_known_tablets Whether to reload the tablet's address/port map from topo in case they change. (default true) --tablet_url_template string Format string describing debug tablet url formatting. See getTabletDebugURL() for how to customize this. (default "http://{{ "{{.GetTabletHostPort}}" }}") --throttle_tablet_types string Comma separated VTTablet types to be considered by the throttler. default: 'replica'. example: 'replica,rdonly'. 'replica' always implicitly included (default "replica") + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_etcd_lease_ttl int Lease TTL for locks and leader election. The client will use KeepAlive to keep the lease going. (default 30) --topo_etcd_tls_ca string path to the ca to use to validate the server cert when connecting to the etcd topo server diff --git a/go/flags/endtoend/vtctld.txt b/go/flags/endtoend/vtctld.txt index da0cef558e5..4cb5c1e5082 100644 --- a/go/flags/endtoend/vtctld.txt +++ b/go/flags/endtoend/vtctld.txt @@ -83,6 +83,7 @@ Flags: --grpc_server_initial_window_size int gRPC server initial window size --grpc_server_keepalive_enforcement_policy_min_time duration gRPC server minimum keepalive time (default 10s) --grpc_server_keepalive_enforcement_policy_permit_without_stream gRPC server permit client keepalive pings even when there are no active streams (RPCs) + --healthcheck-dial-concurrency int Maximum concurrency of new healthcheck connections. This should be less than the golang max thread limit of 10000. (default 1024) -h, --help help for vtctld --jaeger-agent-host string host and port to send spans to. if empty, no tracing will be done --keep_logs duration keep logs for this long (using ctime) (zero to keep forever) @@ -150,9 +151,12 @@ Flags: --tablet_refresh_interval duration Tablet refresh interval. (default 1m0s) --tablet_refresh_known_tablets Whether to reload the tablet's address/port map from topo in case they change. (default true) --tablet_url_template string Format string describing debug tablet url formatting. See getTabletDebugURL() for how to customize this. (default "http://{{ "{{.GetTabletHostPort}}" }}") + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_etcd_lease_ttl int Lease TTL for locks and leader election. The client will use KeepAlive to keep the lease going. (default 30) --topo_etcd_tls_ca string path to the ca to use to validate the server cert when connecting to the etcd topo server diff --git a/go/flags/endtoend/vtgate.txt b/go/flags/endtoend/vtgate.txt index 0d296c35e7c..f42f6a2f331 100644 --- a/go/flags/endtoend/vtgate.txt +++ b/go/flags/endtoend/vtgate.txt @@ -94,6 +94,7 @@ Flags: --grpc_server_keepalive_enforcement_policy_min_time duration gRPC server minimum keepalive time (default 10s) --grpc_server_keepalive_enforcement_policy_permit_without_stream gRPC server permit client keepalive pings even when there are no active streams (RPCs) --grpc_use_effective_callerid If set, and SSL is not used, will set the immediate caller id from the effective caller id's principal. + --healthcheck-dial-concurrency int Maximum concurrency of new healthcheck connections. This should be less than the golang max thread limit of 10000. (default 1024) --healthcheck_retry_delay duration health check retry delay (default 2ms) --healthcheck_timeout duration the health check timeout period (default 1m0s) -h, --help help for vtgate @@ -203,9 +204,12 @@ Flags: --tablet_refresh_known_tablets Whether to reload the tablet's address/port map from topo in case they change. (default true) --tablet_types_to_wait strings Wait till connected for specified tablet types during Gateway initialization. Should be provided as a comma-separated set of tablet types. --tablet_url_template string Format string describing debug tablet url formatting. See getTabletDebugURL() for how to customize this. (default "http://{{ "{{.GetTabletHostPort}}" }}") + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_etcd_lease_ttl int Lease TTL for locks and leader election. The client will use KeepAlive to keep the lease going. (default 30) --topo_etcd_tls_ca string path to the ca to use to validate the server cert when connecting to the etcd topo server diff --git a/go/flags/endtoend/vtorc.txt b/go/flags/endtoend/vtorc.txt index acb69f43c8a..f65eb12d142 100644 --- a/go/flags/endtoend/vtorc.txt +++ b/go/flags/endtoend/vtorc.txt @@ -89,9 +89,12 @@ Flags: --tablet_manager_protocol string Protocol to use to make tabletmanager RPCs to vttablets. (default "grpc") --tolerable-replication-lag duration Amount of replication lag that is considered acceptable for a tablet to be eligible for promotion when Vitess makes the choice of a new primary in PRS --topo-information-refresh-duration duration Timer duration on which VTOrc refreshes the keyspace and vttablet records from the topology server (default 15s) + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_etcd_lease_ttl int Lease TTL for locks and leader election. The client will use KeepAlive to keep the lease going. (default 30) --topo_etcd_tls_ca string path to the ca to use to validate the server cert when connecting to the etcd topo server diff --git a/go/flags/endtoend/vttablet.txt b/go/flags/endtoend/vttablet.txt index 7eae51c5f4f..dbc14039ec3 100644 --- a/go/flags/endtoend/vttablet.txt +++ b/go/flags/endtoend/vttablet.txt @@ -355,9 +355,12 @@ Flags: --tablet_manager_protocol string Protocol to use to make tabletmanager RPCs to vttablets. (default "grpc") --tablet_protocol string Protocol to use to make queryservice RPCs to vttablets. (default "grpc") --throttle_tablet_types string Comma separated VTTablet types to be considered by the throttler. default: 'replica'. example: 'replica,rdonly'. 'replica' always implicitly included (default "replica") + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_etcd_lease_ttl int Lease TTL for locks and leader election. The client will use KeepAlive to keep the lease going. (default 30) --topo_etcd_tls_ca string path to the ca to use to validate the server cert when connecting to the etcd topo server diff --git a/go/flags/endtoend/vttestserver.txt b/go/flags/endtoend/vttestserver.txt index 72d9d0bbf78..ece7ff2bcec 100644 --- a/go/flags/endtoend/vttestserver.txt +++ b/go/flags/endtoend/vttestserver.txt @@ -127,9 +127,12 @@ Flags: --tablet_manager_grpc_server_name string the server name to use to validate server certificate --tablet_manager_protocol string Protocol to use to make tabletmanager RPCs to vttablets. (default "grpc") --tablet_refresh_interval duration Interval at which vtgate refreshes tablet information from topology server. (default 10s) + --topo_consul_idle_conn_timeout duration Maximum amount of time to pool idle connections. (default 1m30s) --topo_consul_lock_delay duration LockDelay for consul session. (default 15s) --topo_consul_lock_session_checks string List of checks for consul session. (default "serfHealth") --topo_consul_lock_session_ttl string TTL for consul session. + --topo_consul_max_conns_per_host int Maximum number of consul connections per host. (default 250) + --topo_consul_max_idle_conns int Maximum number of idle consul connections. (default 100) --topo_consul_watch_poll_duration duration time of the long poll for watch queries. (default 30s) --topo_zk_auth_file string auth to use when connecting to the zk topo server, file contents should be :, e.g., digest:user:pass --topo_zk_base_timeout duration zk base timeout (see zk.Connect) (default 30s) diff --git a/go/internal/flag/flag.go b/go/internal/flag/flag.go index ade4907e573..6d43191a456 100644 --- a/go/internal/flag/flag.go +++ b/go/internal/flag/flag.go @@ -29,10 +29,13 @@ import ( "os" "reflect" "strings" + "sync" flag "github.com/spf13/pflag" ) +var flagsMu sync.Mutex + // Parse wraps the standard library's flag.Parse to perform some sanity checking // and issue deprecation warnings in advance of our move to pflag. // @@ -42,6 +45,8 @@ import ( // // See VEP-4, phase 1 for details: https://github.com/vitessio/enhancements/blob/c766ea905e55409cddeb666d6073cd2ac4c9783e/veps/vep-4.md#phase-1-preparation func Parse(fs *flag.FlagSet) { + flagsMu.Lock() + defer flagsMu.Unlock() PreventGlogVFlagFromClobberingVersionFlagShorthand(fs) fs.AddGoFlagSet(goflag.CommandLine) @@ -70,6 +75,8 @@ func Parse(fs *flag.FlagSet) { // IsFlagProvided returns if the given flag has been provided by the user explicitly or not func IsFlagProvided(name string) bool { + flagsMu.Lock() + defer flagsMu.Unlock() fl := flag.Lookup(name) if fl != nil { return fl.Changed @@ -167,6 +174,8 @@ func filterTestFlags() ([]string, []string) { // handle `go test` flags correctly. We need to separately parse the test flags using goflags. Additionally flags // like test.Short() require that goflag.Parse() is called first. func ParseFlagsForTest() { + flagsMu.Lock() + defer flagsMu.Unlock() // We need to split up the test flags and the regular app pflags. // Then hand them off the std flags and pflags parsers respectively. args, testFlags := filterTestFlags() @@ -198,6 +207,8 @@ func Parsed() bool { // standard library `flag` CommandLine. If found in the latter, it is converted // to a pflag.Flag first. If found in neither, this function returns nil. func Lookup(name string) *flag.Flag { + flagsMu.Lock() + defer flagsMu.Unlock() if f := flag.Lookup(name); f != nil { return f } @@ -213,6 +224,8 @@ func Lookup(name string) *flag.Flag { // removed. If no double-dash was specified on the command-line, this is // equivalent to flag.Args() from the standard library flag package. func Args() (args []string) { + flagsMu.Lock() + defer flagsMu.Unlock() doubleDashIdx := -1 for i, arg := range flag.Args() { if arg == "--" { diff --git a/go/vt/discovery/healthcheck.go b/go/vt/discovery/healthcheck.go index 5d6a5e32662..f37c9ad1d8b 100644 --- a/go/vt/discovery/healthcheck.go +++ b/go/vt/discovery/healthcheck.go @@ -46,6 +46,7 @@ import ( "github.com/google/safehtml/template" "github.com/google/safehtml/template/uncheckedconversions" "github.com/spf13/pflag" + "golang.org/x/sync/semaphore" "vitess.io/vitess/go/netutil" "vitess.io/vitess/go/stats" @@ -87,6 +88,9 @@ var ( // refreshKnownTablets tells us whether to process all tablets or only new tablets. refreshKnownTablets = true + // healthCheckDialConcurrency tells us how many healthcheck connections can be opened to tablets at once. This should be less than the golang max thread limit of 10000. + healthCheckDialConcurrency int64 = 1024 + // How much to sleep between each check. waitAvailableTabletInterval = 100 * time.Millisecond @@ -168,6 +172,7 @@ func registerWebUIFlags(fs *pflag.FlagSet) { fs.StringVar(&TabletURLTemplateString, "tablet_url_template", "http://{{.GetTabletHostPort}}", "Format string describing debug tablet url formatting. See getTabletDebugURL() for how to customize this.") fs.DurationVar(&refreshInterval, "tablet_refresh_interval", 1*time.Minute, "Tablet refresh interval.") fs.BoolVar(&refreshKnownTablets, "tablet_refresh_known_tablets", true, "Whether to reload the tablet's address/port map from topo in case they change.") + fs.Int64Var(&healthCheckDialConcurrency, "healthcheck-dial-concurrency", 1024, "Maximum concurrency of new healthcheck connections. This should be less than the golang max thread limit of 10000.") ParseTabletURLTemplateFromFlag() } @@ -287,6 +292,8 @@ type HealthCheckImpl struct { subscribers map[chan *TabletHealth]struct{} // loadTablets trigger is used to immediately load a new primary tablet when the current one has been demoted loadTabletsTrigger chan struct{} + // healthCheckDialSem is used to limit how many healthcheck connections can be opened to tablets at once. + healthCheckDialSem *semaphore.Weighted } // NewHealthCheck creates a new HealthCheck object. @@ -321,6 +328,7 @@ func NewHealthCheck(ctx context.Context, retryDelay, healthCheckTimeout time.Dur cell: localCell, retryDelay: retryDelay, healthCheckTimeout: healthCheckTimeout, + healthCheckDialSem: semaphore.NewWeighted(healthCheckDialConcurrency), healthByAlias: make(map[tabletAliasString]*tabletHealthCheck), healthData: make(map[KeyspaceShardTabletType]map[tabletAliasString]*TabletHealth), healthy: make(map[KeyspaceShardTabletType][]*TabletHealth), @@ -750,30 +758,8 @@ func (hc *HealthCheckImpl) WaitForAllServingTablets(ctx context.Context, targets return hc.waitForTablets(ctx, targets, true) } -// FilterTargetsByKeyspaces only returns the targets that are part of the provided keyspaces -func FilterTargetsByKeyspaces(keyspaces []string, targets []*query.Target) []*query.Target { - filteredTargets := make([]*query.Target, 0) - - // Keep them all if there are no keyspaces to watch - if len(KeyspacesToWatch) == 0 { - return append(filteredTargets, targets...) - } - - // Let's remove from the target shards that are not in the keyspaceToWatch list. - for _, target := range targets { - for _, keyspaceToWatch := range keyspaces { - if target.Keyspace == keyspaceToWatch { - filteredTargets = append(filteredTargets, target) - } - } - } - return filteredTargets -} - // waitForTablets is the internal method that polls for tablets. func (hc *HealthCheckImpl) waitForTablets(ctx context.Context, targets []*query.Target, requireServing bool) error { - targets = FilterTargetsByKeyspaces(KeyspacesToWatch, targets) - for { // We nil targets as we find them. allPresent := true @@ -850,7 +836,7 @@ func (hc *HealthCheckImpl) TabletConnection(alias *topodata.TabletAlias, target // TODO: test that throws this error return nil, vterrors.Errorf(vtrpc.Code_NOT_FOUND, "tablet: %v is either down or nonexistent", alias) } - return thc.Connection(), nil + return thc.Connection(hc), nil } // getAliasByCell should only be called while holding hc.mu diff --git a/go/vt/discovery/healthcheck_test.go b/go/vt/discovery/healthcheck_test.go index 9563d9bfdc5..31376bd8c7d 100644 --- a/go/vt/discovery/healthcheck_test.go +++ b/go/vt/discovery/healthcheck_test.go @@ -672,27 +672,6 @@ func TestWaitForAllServingTablets(t *testing.T) { err = hc.WaitForAllServingTablets(ctx, targets) assert.NotNil(t, err, "error should not be nil (there are no tablets on this keyspace") - - targets = []*querypb.Target{ - - { - Keyspace: tablet.Keyspace, - Shard: tablet.Shard, - TabletType: tablet.Type, - }, - { - Keyspace: "newkeyspace", - Shard: tablet.Shard, - TabletType: tablet.Type, - }, - } - - KeyspacesToWatch = []string{tablet.Keyspace} - - err = hc.WaitForAllServingTablets(ctx, targets) - assert.Nil(t, err, "error should be nil. Keyspace with no tablets is filtered") - - KeyspacesToWatch = []string{} } // TestRemoveTablet tests the behavior when a tablet goes away. diff --git a/go/vt/discovery/tablet_health_check.go b/go/vt/discovery/tablet_health_check.go index 24496155e74..fc3ab242210 100644 --- a/go/vt/discovery/tablet_health_check.go +++ b/go/vt/discovery/tablet_health_check.go @@ -19,6 +19,7 @@ package discovery import ( "context" "fmt" + "net" "strings" "sync" "sync/atomic" @@ -33,12 +34,16 @@ import ( "vitess.io/vitess/go/vt/vttablet/queryservice" "vitess.io/vitess/go/vt/vttablet/tabletconn" + "google.golang.org/grpc" "google.golang.org/protobuf/proto" "vitess.io/vitess/go/vt/proto/query" "vitess.io/vitess/go/vt/proto/topodata" ) +// withDialerContextOnce ensures grpc.WithDialContext() is added once to the options. +var withDialerContextOnce sync.Once + // tabletHealthCheck maintains the health status of a tablet. A map of this // structure is maintained in HealthCheck. type tabletHealthCheck struct { @@ -122,8 +127,8 @@ func (thc *tabletHealthCheck) setServingState(serving bool, reason string) { } // stream streams healthcheck responses to callback. -func (thc *tabletHealthCheck) stream(ctx context.Context, callback func(*query.StreamHealthResponse) error) error { - conn := thc.Connection() +func (thc *tabletHealthCheck) stream(ctx context.Context, hc *HealthCheckImpl, callback func(*query.StreamHealthResponse) error) error { + conn := thc.Connection(hc) if conn == nil { // This signals the caller to retry return nil @@ -136,14 +141,34 @@ func (thc *tabletHealthCheck) stream(ctx context.Context, callback func(*query.S return err } -func (thc *tabletHealthCheck) Connection() queryservice.QueryService { +func (thc *tabletHealthCheck) Connection(hc *HealthCheckImpl) queryservice.QueryService { thc.connMu.Lock() defer thc.connMu.Unlock() - return thc.connectionLocked() + return thc.connectionLocked(hc) +} + +func healthCheckDialerFactory(hc *HealthCheckImpl) func(ctx context.Context, addr string) (net.Conn, error) { + return func(ctx context.Context, addr string) (net.Conn, error) { + // Limit the number of healthcheck connections opened in parallel to avoid high OS-thread + // usage due to blocking networking syscalls (eg: DNS lookups, TCP connection opens, + // etc). Without this limit it is possible for vtgates watching >10k tablets to hit + // the panic: 'runtime: program exceeds 10000-thread limit'. + if err := hc.healthCheckDialSem.Acquire(ctx, 1); err != nil { + return nil, err + } + defer hc.healthCheckDialSem.Release(1) + var dialer net.Dialer + return dialer.DialContext(ctx, "tcp", addr) + } } -func (thc *tabletHealthCheck) connectionLocked() queryservice.QueryService { +func (thc *tabletHealthCheck) connectionLocked(hc *HealthCheckImpl) queryservice.QueryService { if thc.Conn == nil { + withDialerContextOnce.Do(func() { + grpcclient.RegisterGRPCDialOptions(func(opts []grpc.DialOption) ([]grpc.DialOption, error) { + return append(opts, grpc.WithContextDialer(healthCheckDialerFactory(hc))), nil + }) + }) conn, err := tabletconn.GetDialer()(thc.Tablet, grpcclient.FailFast(true)) if err != nil { thc.LastError = err @@ -272,7 +297,7 @@ func (thc *tabletHealthCheck) checkConn(hc *HealthCheckImpl) { }() // Read stream health responses. - err := thc.stream(streamCtx, func(shr *query.StreamHealthResponse) error { + err := thc.stream(streamCtx, hc, func(shr *query.StreamHealthResponse) error { // We received a message. Reset the back-off. retryDelay = hc.retryDelay // Don't block on send to avoid deadlocks. diff --git a/go/vt/grpcclient/client.go b/go/vt/grpcclient/client.go index b2ef0d4fb28..7524298514e 100644 --- a/go/vt/grpcclient/client.go +++ b/go/vt/grpcclient/client.go @@ -21,6 +21,7 @@ package grpcclient import ( "context" "crypto/tls" + "sync" "time" grpc_middleware "github.com/grpc-ecosystem/go-grpc-middleware" @@ -39,6 +40,7 @@ import ( ) var ( + grpcDialOptionsMu sync.Mutex keepaliveTime = 10 * time.Second keepaliveTimeout = 10 * time.Second initialConnWindowSize int @@ -86,6 +88,8 @@ var grpcDialOptions []func(opts []grpc.DialOption) ([]grpc.DialOption, error) // RegisterGRPCDialOptions registers an implementation of AuthServer. func RegisterGRPCDialOptions(grpcDialOptionsFunc func(opts []grpc.DialOption) ([]grpc.DialOption, error)) { + grpcDialOptionsMu.Lock() + defer grpcDialOptionsMu.Unlock() grpcDialOptions = append(grpcDialOptions, grpcDialOptionsFunc) } @@ -134,12 +138,14 @@ func DialContext(ctx context.Context, target string, failFast FailFast, opts ... newopts = append(newopts, opts...) var err error + grpcDialOptionsMu.Lock() for _, grpcDialOptionInitializer := range grpcDialOptions { newopts, err = grpcDialOptionInitializer(newopts) if err != nil { log.Fatalf("There was an error initializing client grpc.DialOption: %v", err) } } + grpcDialOptionsMu.Unlock() newopts = append(newopts, interceptors()...) diff --git a/go/vt/grpcclient/client_auth_static.go b/go/vt/grpcclient/client_auth_static.go index 22f69569956..bbb91a9fa55 100644 --- a/go/vt/grpcclient/client_auth_static.go +++ b/go/vt/grpcclient/client_auth_static.go @@ -20,24 +20,35 @@ import ( "context" "encoding/json" "os" + "os/signal" + "sync" + "syscall" "google.golang.org/grpc" "google.golang.org/grpc/credentials" + + "vitess.io/vitess/go/vt/servenv" ) var ( credsFile string // registered as --grpc_auth_static_client_creds in RegisterFlags // StaticAuthClientCreds implements client interface to be able to WithPerRPCCredentials _ credentials.PerRPCCredentials = (*StaticAuthClientCreds)(nil) + + clientCreds *StaticAuthClientCreds + clientCredsCancel context.CancelFunc + clientCredsErr error + clientCredsMu sync.Mutex + clientCredsSigChan chan os.Signal ) -// StaticAuthClientCreds holder for client credentials +// StaticAuthClientCreds holder for client credentials. type StaticAuthClientCreds struct { Username string Password string } -// GetRequestMetadata gets the request metadata as a map from StaticAuthClientCreds +// GetRequestMetadata gets the request metadata as a map from StaticAuthClientCreds. func (c *StaticAuthClientCreds) GetRequestMetadata(context.Context, ...string) (map[string]string, error) { return map[string]string{ "username": c.Username, @@ -47,30 +58,82 @@ func (c *StaticAuthClientCreds) GetRequestMetadata(context.Context, ...string) ( // RequireTransportSecurity indicates whether the credentials requires transport security. // Given that people can use this with or without TLS, at the moment we are not enforcing -// transport security +// transport security. func (c *StaticAuthClientCreds) RequireTransportSecurity() bool { return false } // AppendStaticAuth optionally appends static auth credentials if provided. func AppendStaticAuth(opts []grpc.DialOption) ([]grpc.DialOption, error) { - if credsFile == "" { - return opts, nil - } - data, err := os.ReadFile(credsFile) + creds, err := getStaticAuthCreds() if err != nil { return nil, err } - clientCreds := &StaticAuthClientCreds{} - err = json.Unmarshal(data, clientCreds) + if creds != nil { + grpcCreds := grpc.WithPerRPCCredentials(creds) + opts = append(opts, grpcCreds) + } + return opts, nil +} + +// ResetStaticAuth resets the static auth credentials. +func ResetStaticAuth() { + clientCredsMu.Lock() + defer clientCredsMu.Unlock() + if clientCredsCancel != nil { + clientCredsCancel() + clientCredsCancel = nil + } + clientCreds = nil + clientCredsErr = nil +} + +// getStaticAuthCreds returns the static auth creds and error. +func getStaticAuthCreds() (*StaticAuthClientCreds, error) { + clientCredsMu.Lock() + defer clientCredsMu.Unlock() + if credsFile != "" && clientCreds == nil { + var ctx context.Context + ctx, clientCredsCancel = context.WithCancel(context.Background()) + go handleClientCredsSignals(ctx) + clientCreds, clientCredsErr = loadStaticAuthCredsFromFile(credsFile) + } + return clientCreds, clientCredsErr +} + +// handleClientCredsSignals handles signals to reload client creds. +func handleClientCredsSignals(ctx context.Context) { + for { + select { + case <-ctx.Done(): + return + case <-clientCredsSigChan: + if newCreds, err := loadStaticAuthCredsFromFile(credsFile); err == nil { + clientCredsMu.Lock() + clientCreds = newCreds + clientCredsErr = err + clientCredsMu.Unlock() + } + } + } +} + +// loadStaticAuthCredsFromFile loads static auth credentials from a file. +func loadStaticAuthCredsFromFile(path string) (*StaticAuthClientCreds, error) { + data, err := os.ReadFile(path) if err != nil { return nil, err } - creds := grpc.WithPerRPCCredentials(clientCreds) - opts = append(opts, creds) - return opts, nil + creds := &StaticAuthClientCreds{} + err = json.Unmarshal(data, creds) + return creds, err } func init() { + servenv.OnInit(func() { + clientCredsSigChan = make(chan os.Signal, 1) + signal.Notify(clientCredsSigChan, syscall.SIGHUP) + _, _ = getStaticAuthCreds() // preload static auth credentials + }) RegisterGRPCDialOptions(AppendStaticAuth) } diff --git a/go/vt/grpcclient/client_auth_static_test.go b/go/vt/grpcclient/client_auth_static_test.go new file mode 100644 index 00000000000..e14ace527d1 --- /dev/null +++ b/go/vt/grpcclient/client_auth_static_test.go @@ -0,0 +1,126 @@ +/* +Copyright 2024 The Vitess 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 + + http://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. +*/ + +package grpcclient + +import ( + "errors" + "fmt" + "os" + "reflect" + "syscall" + "testing" + "time" + + "github.com/stretchr/testify/assert" + "google.golang.org/grpc" +) + +func TestAppendStaticAuth(t *testing.T) { + { + clientCreds = nil + clientCredsErr = nil + opts, err := AppendStaticAuth([]grpc.DialOption{}) + assert.Nil(t, err) + assert.Len(t, opts, 0) + } + { + clientCreds = nil + clientCredsErr = errors.New("test err") + opts, err := AppendStaticAuth([]grpc.DialOption{}) + assert.NotNil(t, err) + assert.Len(t, opts, 0) + } + { + clientCreds = &StaticAuthClientCreds{Username: "test", Password: "123456"} + clientCredsErr = nil + opts, err := AppendStaticAuth([]grpc.DialOption{}) + assert.Nil(t, err) + assert.Len(t, opts, 1) + } +} + +func TestGetStaticAuthCreds(t *testing.T) { + tmp, err := os.CreateTemp("", t.Name()) + assert.Nil(t, err) + defer os.Remove(tmp.Name()) + credsFile = tmp.Name() + clientCredsSigChan = make(chan os.Signal, 1) + + // load old creds + fmt.Fprint(tmp, `{"Username": "old", "Password": "123456"}`) + ResetStaticAuth() + creds, err := getStaticAuthCreds() + assert.Nil(t, err) + assert.Equal(t, &StaticAuthClientCreds{Username: "old", Password: "123456"}, creds) + + // write new creds to the same file + _ = tmp.Truncate(0) + _, _ = tmp.Seek(0, 0) + fmt.Fprint(tmp, `{"Username": "new", "Password": "123456789"}`) + + // test the creds did not change yet + creds, err = getStaticAuthCreds() + assert.Nil(t, err) + assert.Equal(t, &StaticAuthClientCreds{Username: "old", Password: "123456"}, creds) + + // test SIGHUP signal triggers reload + credsOld := creds + clientCredsSigChan <- syscall.SIGHUP + timeoutChan := time.After(time.Second * 10) + for { + select { + case <-timeoutChan: + assert.Fail(t, "timed out waiting for SIGHUP reload of static auth creds") + return + default: + // confirm new creds get loaded + creds, err = getStaticAuthCreds() + if reflect.DeepEqual(creds, credsOld) { + continue // not changed yet + } + assert.Nil(t, err) + assert.Equal(t, &StaticAuthClientCreds{Username: "new", Password: "123456789"}, creds) + return + } + } +} + +func TestLoadStaticAuthCredsFromFile(t *testing.T) { + { + f, err := os.CreateTemp("", t.Name()) + if !assert.Nil(t, err) { + assert.FailNowf(t, "cannot create temp file: %s", err.Error()) + } + defer os.Remove(f.Name()) + fmt.Fprint(f, `{ + "Username": "test", + "Password": "correct horse battery staple" + }`) + if !assert.Nil(t, err) { + assert.FailNowf(t, "cannot read auth file: %s", err.Error()) + } + + creds, err := loadStaticAuthCredsFromFile(f.Name()) + assert.Nil(t, err) + assert.Equal(t, "test", creds.Username) + assert.Equal(t, "correct horse battery staple", creds.Password) + } + { + _, err := loadStaticAuthCredsFromFile(`does-not-exist`) + assert.NotNil(t, err) + } +} diff --git a/go/vt/srvtopo/discover.go b/go/vt/srvtopo/discover.go index 91aaea9daf6..2997dc42e21 100644 --- a/go/vt/srvtopo/discover.go +++ b/go/vt/srvtopo/discover.go @@ -29,20 +29,23 @@ import ( topodatapb "vitess.io/vitess/go/vt/proto/topodata" ) -// FindAllTargets goes through all serving shards in the topology -// for the provided tablet types. It returns one Target object per -// keyspace / shard / matching TabletType. -func FindAllTargets(ctx context.Context, ts Server, cell string, tabletTypes []topodatapb.TabletType) ([]*querypb.Target, error) { - ksNames, err := ts.GetSrvKeyspaceNames(ctx, cell, true) - if err != nil { - return nil, err +// FindAllTargets goes through all serving shards in the topology for the provided keyspaces +// and tablet types. If no keyspaces are provided all available keyspaces in the topo are +// fetched. It returns one Target object per keyspace/shard/matching TabletType. +func FindAllTargets(ctx context.Context, ts Server, cell string, keyspaces []string, tabletTypes []topodatapb.TabletType) ([]*querypb.Target, error) { + var err error + if len(keyspaces) == 0 { + keyspaces, err = ts.GetSrvKeyspaceNames(ctx, cell, true) + if err != nil { + return nil, err + } } var targets []*querypb.Target var wg sync.WaitGroup var mu sync.Mutex var errRecorder concurrency.AllErrorRecorder - for _, ksName := range ksNames { + for _, ksName := range keyspaces { wg.Add(1) go func(keyspace string) { defer wg.Done() diff --git a/go/vt/srvtopo/discover_test.go b/go/vt/srvtopo/discover_test.go index ca4774a1b84..3f730bba3d3 100644 --- a/go/vt/srvtopo/discover_test.go +++ b/go/vt/srvtopo/discover_test.go @@ -18,11 +18,12 @@ package srvtopo import ( "context" - "reflect" "sort" "testing" "time" + "github.com/stretchr/testify/assert" + "vitess.io/vitess/go/vt/topo/memorytopo" querypb "vitess.io/vitess/go/vt/proto/query" @@ -62,16 +63,12 @@ func TestFindAllTargets(t *testing.T) { rs := NewResilientServer(ctx, ts, "TestFindAllKeyspaceShards") // No keyspace / shards. - ks, err := FindAllTargets(ctx, rs, "cell1", []topodatapb.TabletType{topodatapb.TabletType_PRIMARY}) - if err != nil { - t.Errorf("unexpected error: %v", err) - } - if len(ks) > 0 { - t.Errorf("why did I get anything? %v", ks) - } + ks, err := FindAllTargets(ctx, rs, "cell1", []string{"test_keyspace"}, []topodatapb.TabletType{topodatapb.TabletType_PRIMARY}) + assert.NoError(t, err) + assert.Len(t, ks, 0) // Add one. - if err := ts.UpdateSrvKeyspace(ctx, "cell1", "test_keyspace", &topodatapb.SrvKeyspace{ + assert.NoError(t, ts.UpdateSrvKeyspace(ctx, "cell1", "test_keyspace", &topodatapb.SrvKeyspace{ Partitions: []*topodatapb.SrvKeyspace_KeyspacePartition{ { ServedType: topodatapb.TabletType_PRIMARY, @@ -82,28 +79,34 @@ func TestFindAllTargets(t *testing.T) { }, }, }, - }); err != nil { - t.Fatalf("can't add srvKeyspace: %v", err) - } + })) // Get it. - ks, err = FindAllTargets(ctx, rs, "cell1", []topodatapb.TabletType{topodatapb.TabletType_PRIMARY}) - if err != nil { - t.Errorf("unexpected error: %v", err) - } - if !reflect.DeepEqual(ks, []*querypb.Target{ + ks, err = FindAllTargets(ctx, rs, "cell1", []string{"test_keyspace"}, []topodatapb.TabletType{topodatapb.TabletType_PRIMARY}) + assert.NoError(t, err) + assert.EqualValues(t, []*querypb.Target{ { Cell: "cell1", Keyspace: "test_keyspace", Shard: "test_shard0", TabletType: topodatapb.TabletType_PRIMARY, }, - }) { - t.Errorf("got wrong value: %v", ks) - } + }, ks) + + // Get any keyspace. + ks, err = FindAllTargets(ctx, rs, "cell1", nil, []topodatapb.TabletType{topodatapb.TabletType_PRIMARY}) + assert.NoError(t, err) + assert.EqualValues(t, []*querypb.Target{ + { + Cell: "cell1", + Keyspace: "test_keyspace", + Shard: "test_shard0", + TabletType: topodatapb.TabletType_PRIMARY, + }, + }, ks) // Add another one. - if err := ts.UpdateSrvKeyspace(ctx, "cell1", "test_keyspace2", &topodatapb.SrvKeyspace{ + assert.NoError(t, ts.UpdateSrvKeyspace(ctx, "cell1", "test_keyspace2", &topodatapb.SrvKeyspace{ Partitions: []*topodatapb.SrvKeyspace_KeyspacePartition{ { ServedType: topodatapb.TabletType_PRIMARY, @@ -122,17 +125,13 @@ func TestFindAllTargets(t *testing.T) { }, }, }, - }); err != nil { - t.Fatalf("can't add srvKeyspace: %v", err) - } + })) - // Get it for all types. - ks, err = FindAllTargets(ctx, rs, "cell1", []topodatapb.TabletType{topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA}) - if err != nil { - t.Errorf("unexpected error: %v", err) - } + // Get it for any keyspace, all types. + ks, err = FindAllTargets(ctx, rs, "cell1", nil, []topodatapb.TabletType{topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA}) + assert.NoError(t, err) sort.Sort(TargetArray(ks)) - if !reflect.DeepEqual(ks, []*querypb.Target{ + assert.EqualValues(t, []*querypb.Target{ { Cell: "cell1", Keyspace: "test_keyspace", @@ -151,23 +150,40 @@ func TestFindAllTargets(t *testing.T) { Shard: "test_shard2", TabletType: topodatapb.TabletType_REPLICA, }, - }) { - t.Errorf("got wrong value: %v", ks) - } + }, ks) - // Only get the REPLICA targets. - ks, err = FindAllTargets(ctx, rs, "cell1", []topodatapb.TabletType{topodatapb.TabletType_REPLICA}) - if err != nil { - t.Errorf("unexpected error: %v", err) - } - if !reflect.DeepEqual(ks, []*querypb.Target{ + // Only get 1 keyspace for all types. + ks, err = FindAllTargets(ctx, rs, "cell1", []string{"test_keyspace2"}, []topodatapb.TabletType{topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA}) + assert.NoError(t, err) + assert.EqualValues(t, []*querypb.Target{ + { + Cell: "cell1", + Keyspace: "test_keyspace2", + Shard: "test_shard1", + TabletType: topodatapb.TabletType_PRIMARY, + }, { Cell: "cell1", Keyspace: "test_keyspace2", Shard: "test_shard2", TabletType: topodatapb.TabletType_REPLICA, }, - }) { - t.Errorf("got wrong value: %v", ks) - } + }, ks) + + // Only get the REPLICA targets for any keyspace. + ks, err = FindAllTargets(ctx, rs, "cell1", []string{}, []topodatapb.TabletType{topodatapb.TabletType_REPLICA}) + assert.NoError(t, err) + assert.Equal(t, []*querypb.Target{ + { + Cell: "cell1", + Keyspace: "test_keyspace2", + Shard: "test_shard2", + TabletType: topodatapb.TabletType_REPLICA, + }, + }, ks) + + // Get non-existent keyspace. + ks, err = FindAllTargets(ctx, rs, "cell1", []string{"doesnt-exist"}, []topodatapb.TabletType{topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA}) + assert.NoError(t, err) + assert.Len(t, ks, 0) } diff --git a/go/vt/topo/consultopo/server.go b/go/vt/topo/consultopo/server.go index a7a5446c274..0a059b12f65 100644 --- a/go/vt/topo/consultopo/server.go +++ b/go/vt/topo/consultopo/server.go @@ -27,6 +27,7 @@ import ( "time" "github.com/hashicorp/consul/api" + "github.com/hashicorp/go-cleanhttp" "github.com/spf13/pflag" "vitess.io/vitess/go/vt/log" @@ -40,7 +41,10 @@ var ( // serfHealth is the default check from consul consulLockSessionChecks = "serfHealth" consulLockSessionTTL string - consulLockDelay = 15 * time.Second + consulLockDelay = 15 * time.Second + consulMaxConnsPerHost int = 250 // do not use client default of 0/unlimited + consulMaxIdleConns int + consulIdleConnTimeout time.Duration ) func init() { @@ -48,10 +52,18 @@ func init() { } func registerServerFlags(fs *pflag.FlagSet) { + // cleanhttp.DefaultPooledTransport() is used by the consul api client + // as an *http.Transport. We call it here just to get the default + // values the consul api client will inherit from it later. + defaultConsulPooledTransport := cleanhttp.DefaultPooledTransport() + fs.StringVar(&consulAuthClientStaticFile, "consul_auth_static_file", consulAuthClientStaticFile, "JSON File to read the topos/tokens from.") fs.StringVar(&consulLockSessionChecks, "topo_consul_lock_session_checks", consulLockSessionChecks, "List of checks for consul session.") fs.StringVar(&consulLockSessionTTL, "topo_consul_lock_session_ttl", consulLockSessionTTL, "TTL for consul session.") fs.DurationVar(&consulLockDelay, "topo_consul_lock_delay", consulLockDelay, "LockDelay for consul session.") + fs.IntVar(&consulMaxConnsPerHost, "topo_consul_max_conns_per_host", consulMaxConnsPerHost, "Maximum number of consul connections per host.") + fs.IntVar(&consulMaxIdleConns, "topo_consul_max_idle_conns", defaultConsulPooledTransport.MaxIdleConns, "Maximum number of idle consul connections.") + fs.DurationVar(&consulIdleConnTimeout, "topo_consul_idle_conn_timeout", defaultConsulPooledTransport.IdleConnTimeout, "Maximum amount of time to pool idle connections.") } // ClientAuthCred credential to use for consul clusters @@ -132,6 +144,9 @@ func NewServer(cell, serverAddr, root string) (*Server, error) { } cfg := api.DefaultConfig() cfg.Address = serverAddr + cfg.Transport.MaxConnsPerHost = consulMaxConnsPerHost + cfg.Transport.MaxIdleConns = consulMaxIdleConns + cfg.Transport.IdleConnTimeout = consulIdleConnTimeout if creds != nil { if creds[cell] != nil { cfg.Token = creds[cell].ACLToken diff --git a/go/vt/vtctl/grpcvtctldserver/testutil/test_tmclient.go b/go/vt/vtctl/grpcvtctldserver/testutil/test_tmclient.go index 736bda4a1f4..f6e5ba8c72d 100644 --- a/go/vt/vtctl/grpcvtctldserver/testutil/test_tmclient.go +++ b/go/vt/vtctl/grpcvtctldserver/testutil/test_tmclient.go @@ -186,6 +186,7 @@ type TabletManagerClient struct { } // keyed by tablet alias. ChangeTabletTypeResult map[string]error + ChangeTabletTypeDelays map[string]time.Duration // keyed by tablet alias. DemotePrimaryDelays map[string]time.Duration // keyed by tablet alias. @@ -461,7 +462,20 @@ func (fake *TabletManagerClient) Backup(ctx context.Context, tablet *topodatapb. // ChangeType is part of the tmclient.TabletManagerClient interface. func (fake *TabletManagerClient) ChangeType(ctx context.Context, tablet *topodatapb.Tablet, newType topodatapb.TabletType, semiSync bool) error { - if result, ok := fake.ChangeTabletTypeResult[topoproto.TabletAliasString(tablet.Alias)]; ok { + key := topoproto.TabletAliasString(tablet.Alias) + + if fake.ChangeTabletTypeDelays != nil { + if delay, ok := fake.ChangeTabletTypeDelays[key]; ok { + select { + case <-ctx.Done(): + return ctx.Err() + case <-time.After(delay): + // proceed to results + } + } + } + + if result, ok := fake.ChangeTabletTypeResult[key]; ok { return result } diff --git a/go/vt/vtctl/reparentutil/durability.go b/go/vt/vtctl/reparentutil/durability.go index e68485a395c..29a5b2e712a 100644 --- a/go/vt/vtctl/reparentutil/durability.go +++ b/go/vt/vtctl/reparentutil/durability.go @@ -69,13 +69,13 @@ func init() { // Durabler is the interface which is used to get the promotion rules for candidates and the semi sync setup type Durabler interface { - // promotionRule represents the precedence in which we want to tablets to be promoted. + // PromotionRule represents the precedence in which we want to tablets to be promoted. // The higher the promotion rule of a tablet, the more we want it to be promoted in case of a failover - promotionRule(*topodatapb.Tablet) promotionrule.CandidatePromotionRule - // semiSyncAckers represents the number of semi-sync ackers required for a given tablet if it were to become the PRIMARY instance - semiSyncAckers(*topodatapb.Tablet) int - // isReplicaSemiSync returns whether the "replica" should send semi-sync acks if "primary" were to become the PRIMARY instance - isReplicaSemiSync(primary, replica *topodatapb.Tablet) bool + PromotionRule(*topodatapb.Tablet) promotionrule.CandidatePromotionRule + // SemiSyncAckers represents the number of semi-sync ackers required for a given tablet if it were to become the PRIMARY instance + SemiSyncAckers(*topodatapb.Tablet) int + // IsReplicaSemiSync returns whether the "replica" should send semi-sync acks if "primary" were to become the PRIMARY instance + IsReplicaSemiSync(primary, replica *topodatapb.Tablet) bool } func RegisterDurability(name string, newDurablerFunc NewDurabler) { @@ -108,13 +108,13 @@ func PromotionRule(durability Durabler, tablet *topodatapb.Tablet) promotionrule if tablet == nil || tablet.Alias == nil { return promotionrule.MustNot } - return durability.promotionRule(tablet) + return durability.PromotionRule(tablet) } // SemiSyncAckers returns the primary semi-sync setting for the instance. // 0 means none. Non-zero specifies the number of required ackers. func SemiSyncAckers(durability Durabler, tablet *topodatapb.Tablet) int { - return durability.semiSyncAckers(tablet) + return durability.SemiSyncAckers(tablet) } // IsReplicaSemiSync returns the replica semi-sync setting from the tablet record. @@ -124,7 +124,7 @@ func IsReplicaSemiSync(durability Durabler, primary, replica *topodatapb.Tablet) if primary == nil || primary.Alias == nil || replica == nil || replica.Alias == nil { return false } - return durability.isReplicaSemiSync(primary, replica) + return durability.IsReplicaSemiSync(primary, replica) } //======================================================================= @@ -132,8 +132,8 @@ func IsReplicaSemiSync(durability Durabler, primary, replica *topodatapb.Tablet) // durabilityNone has no semi-sync and returns NeutralPromoteRule for Primary and Replica tablet types, MustNotPromoteRule for everything else type durabilityNone struct{} -// promotionRule implements the Durabler interface -func (d *durabilityNone) promotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { +// PromotionRule implements the Durabler interface +func (d *durabilityNone) PromotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { switch tablet.Type { case topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA: return promotionrule.Neutral @@ -141,13 +141,13 @@ func (d *durabilityNone) promotionRule(tablet *topodatapb.Tablet) promotionrule. return promotionrule.MustNot } -// semiSyncAckers implements the Durabler interface -func (d *durabilityNone) semiSyncAckers(tablet *topodatapb.Tablet) int { +// SemiSyncAckers implements the Durabler interface +func (d *durabilityNone) SemiSyncAckers(tablet *topodatapb.Tablet) int { return 0 } -// isReplicaSemiSync implements the Durabler interface -func (d *durabilityNone) isReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { +// IsReplicaSemiSync implements the Durabler interface +func (d *durabilityNone) IsReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { return false } @@ -159,8 +159,8 @@ type durabilitySemiSync struct { rdonlySemiSync bool } -// promotionRule implements the Durabler interface -func (d *durabilitySemiSync) promotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { +// PromotionRule implements the Durabler interface +func (d *durabilitySemiSync) PromotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { switch tablet.Type { case topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA: return promotionrule.Neutral @@ -168,13 +168,13 @@ func (d *durabilitySemiSync) promotionRule(tablet *topodatapb.Tablet) promotionr return promotionrule.MustNot } -// semiSyncAckers implements the Durabler interface -func (d *durabilitySemiSync) semiSyncAckers(tablet *topodatapb.Tablet) int { +// SemiSyncAckers implements the Durabler interface +func (d *durabilitySemiSync) SemiSyncAckers(tablet *topodatapb.Tablet) int { return 1 } -// isReplicaSemiSync implements the Durabler interface -func (d *durabilitySemiSync) isReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { +// IsReplicaSemiSync implements the Durabler interface +func (d *durabilitySemiSync) IsReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { switch replica.Type { case topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA: return true @@ -193,8 +193,8 @@ type durabilityCrossCell struct { rdonlySemiSync bool } -// promotionRule implements the Durabler interface -func (d *durabilityCrossCell) promotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { +// PromotionRule implements the Durabler interface +func (d *durabilityCrossCell) PromotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { switch tablet.Type { case topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA: return promotionrule.Neutral @@ -202,13 +202,13 @@ func (d *durabilityCrossCell) promotionRule(tablet *topodatapb.Tablet) promotion return promotionrule.MustNot } -// semiSyncAckers implements the Durabler interface -func (d *durabilityCrossCell) semiSyncAckers(tablet *topodatapb.Tablet) int { +// SemiSyncAckers implements the Durabler interface +func (d *durabilityCrossCell) SemiSyncAckers(tablet *topodatapb.Tablet) int { return 1 } -// isReplicaSemiSync implements the Durabler interface -func (d *durabilityCrossCell) isReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { +// IsReplicaSemiSync implements the Durabler interface +func (d *durabilityCrossCell) IsReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { switch replica.Type { case topodatapb.TabletType_PRIMARY, topodatapb.TabletType_REPLICA: return primary.Alias.Cell != replica.Alias.Cell @@ -223,8 +223,8 @@ func (d *durabilityCrossCell) isReplicaSemiSync(primary, replica *topodatapb.Tab // durabilityTest is like durabilityNone. It overrides the type for a specific tablet to prefer. It is only meant to be used for testing purposes! type durabilityTest struct{} -// promotionRule implements the Durabler interface -func (d *durabilityTest) promotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { +// PromotionRule implements the Durabler interface +func (d *durabilityTest) PromotionRule(tablet *topodatapb.Tablet) promotionrule.CandidatePromotionRule { if topoproto.TabletAliasString(tablet.Alias) == "zone2-0000000200" { return promotionrule.Prefer } @@ -236,12 +236,12 @@ func (d *durabilityTest) promotionRule(tablet *topodatapb.Tablet) promotionrule. return promotionrule.MustNot } -// semiSyncAckers implements the Durabler interface -func (d *durabilityTest) semiSyncAckers(tablet *topodatapb.Tablet) int { +// SemiSyncAckers implements the Durabler interface +func (d *durabilityTest) SemiSyncAckers(tablet *topodatapb.Tablet) int { return 0 } -// isReplicaSemiSync implements the Durabler interface -func (d *durabilityTest) isReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { +// IsReplicaSemiSync implements the Durabler interface +func (d *durabilityTest) IsReplicaSemiSync(primary, replica *topodatapb.Tablet) bool { return false } diff --git a/go/vt/vtctl/reparentutil/durability_test.go b/go/vt/vtctl/reparentutil/durability_test.go index f1429b29621..5745da64f7e 100644 --- a/go/vt/vtctl/reparentutil/durability_test.go +++ b/go/vt/vtctl/reparentutil/durability_test.go @@ -326,7 +326,7 @@ func TestDurabilityTest(t *testing.T) { for _, testcase := range testcases { t.Run(topoproto.TabletAliasString(testcase.tablet.Alias), func(t *testing.T) { - rule := durabilityRules.promotionRule(testcase.tablet) + rule := durabilityRules.PromotionRule(testcase.tablet) assert.Equal(t, testcase.promotionRule, rule) }) } diff --git a/go/vt/vtgate/grpcvtgateconn/conn_rpc_test.go b/go/vt/vtgate/grpcvtgateconn/conn_rpc_test.go index cf272fe3606..55a067807bd 100644 --- a/go/vt/vtgate/grpcvtgateconn/conn_rpc_test.go +++ b/go/vt/vtgate/grpcvtgateconn/conn_rpc_test.go @@ -108,6 +108,7 @@ func TestGRPCVTGateConnAuth(t *testing.T) { fs := pflag.NewFlagSet("", pflag.ContinueOnError) grpcclient.RegisterFlags(fs) + grpcclient.ResetStaticAuth() err = fs.Parse([]string{ "--grpc_auth_static_client_creds", f.Name(), @@ -148,6 +149,7 @@ func TestGRPCVTGateConnAuth(t *testing.T) { fs = pflag.NewFlagSet("", pflag.ContinueOnError) grpcclient.RegisterFlags(fs) + grpcclient.ResetStaticAuth() err = fs.Parse([]string{ "--grpc_auth_static_client_creds", f.Name(), diff --git a/go/vt/vtgate/tabletgateway.go b/go/vt/vtgate/tabletgateway.go index d1846168a43..a5e180c4ddf 100644 --- a/go/vt/vtgate/tabletgateway.go +++ b/go/vt/vtgate/tabletgateway.go @@ -188,7 +188,7 @@ func (gw *TabletGateway) WaitForTablets(ctx context.Context, tabletTypesToWait [ } // Finds the targets to look for. - targets, err := srvtopo.FindAllTargets(ctx, gw.srvTopoServer, gw.localCell, tabletTypesToWait) + targets, err := srvtopo.FindAllTargets(ctx, gw.srvTopoServer, gw.localCell, discovery.KeyspacesToWatch, tabletTypesToWait) if err != nil { return err } diff --git a/go/vt/vtorc/logic/tablet_discovery.go b/go/vt/vtorc/logic/tablet_discovery.go index d0b566cd2af..6914ebd546d 100644 --- a/go/vt/vtorc/logic/tablet_discovery.go +++ b/go/vt/vtorc/logic/tablet_discovery.go @@ -280,27 +280,37 @@ func LockShard(ctx context.Context, tabletAlias string, lockAction string) (cont // tabletUndoDemotePrimary calls the said RPC for the given tablet. func tabletUndoDemotePrimary(ctx context.Context, tablet *topodatapb.Tablet, semiSync bool) error { - return tmc.UndoDemotePrimary(ctx, tablet, semiSync) + tmcCtx, tmcCancel := context.WithTimeout(ctx, topo.RemoteOperationTimeout) + defer tmcCancel() + return tmc.UndoDemotePrimary(tmcCtx, tablet, semiSync) } // setReadOnly calls the said RPC for the given tablet func setReadOnly(ctx context.Context, tablet *topodatapb.Tablet) error { - return tmc.SetReadOnly(ctx, tablet) + tmcCtx, tmcCancel := context.WithTimeout(ctx, topo.RemoteOperationTimeout) + defer tmcCancel() + return tmc.SetReadOnly(tmcCtx, tablet) } // changeTabletType calls the said RPC for the given tablet with the given parameters. func changeTabletType(ctx context.Context, tablet *topodatapb.Tablet, tabletType topodatapb.TabletType, semiSync bool) error { - return tmc.ChangeType(ctx, tablet, tabletType, semiSync) + tmcCtx, tmcCancel := context.WithTimeout(ctx, topo.RemoteOperationTimeout) + defer tmcCancel() + return tmc.ChangeType(tmcCtx, tablet, tabletType, semiSync) } // resetReplicationParameters resets the replication parameters on the given tablet. func resetReplicationParameters(ctx context.Context, tablet *topodatapb.Tablet) error { - return tmc.ResetReplicationParameters(ctx, tablet) + tmcCtx, tmcCancel := context.WithTimeout(ctx, topo.RemoteOperationTimeout) + defer tmcCancel() + return tmc.ResetReplicationParameters(tmcCtx, tablet) } // setReplicationSource calls the said RPC with the parameters provided func setReplicationSource(ctx context.Context, replica *topodatapb.Tablet, primary *topodatapb.Tablet, semiSync bool) error { - return tmc.SetReplicationSource(ctx, replica, primary.Alias, 0, "", true, semiSync) + tmcCtx, tmcCancel := context.WithTimeout(ctx, topo.RemoteOperationTimeout) + defer tmcCancel() + return tmc.SetReplicationSource(tmcCtx, replica, primary.Alias, 0, "", true, semiSync) } // shardPrimary finds the primary of the given keyspace-shard by reading the vtorc backend diff --git a/go/vt/vtorc/logic/tablet_discovery_test.go b/go/vt/vtorc/logic/tablet_discovery_test.go index 0e8ac72fabf..e31b49e4b0e 100644 --- a/go/vt/vtorc/logic/tablet_discovery_test.go +++ b/go/vt/vtorc/logic/tablet_discovery_test.go @@ -21,6 +21,7 @@ import ( "fmt" "sync/atomic" "testing" + "time" "github.com/google/go-cmp/cmp" "github.com/stretchr/testify/assert" @@ -30,8 +31,10 @@ import ( "vitess.io/vitess/go/vt/external/golib/sqlutils" topodatapb "vitess.io/vitess/go/vt/proto/topodata" "vitess.io/vitess/go/vt/proto/vttime" + "vitess.io/vitess/go/vt/topo" "vitess.io/vitess/go/vt/topo/memorytopo" "vitess.io/vitess/go/vt/topo/topoproto" + "vitess.io/vitess/go/vt/vtctl/grpcvtctldserver/testutil" "vitess.io/vitess/go/vt/vtorc/db" "vitess.io/vitess/go/vt/vtorc/inst" ) @@ -342,3 +345,259 @@ func TestGetLockAction(t *testing.T) { }) } } + +func TestSetReadOnly(t *testing.T) { + tests := []struct { + name string + tablet *topodatapb.Tablet + tmc *testutil.TabletManagerClient + remoteOpTimeout time.Duration + errShouldContain string + }{ + { + name: "Success", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + SetReadOnlyResults: map[string]error{ + "zone-1-0000000100": nil, + }, + }, + }, { + name: "Failure", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + SetReadOnlyResults: map[string]error{ + "zone-1-0000000100": fmt.Errorf("testing error"), + }, + }, + errShouldContain: "testing error", + }, { + name: "Timeout", + tablet: tab100, + remoteOpTimeout: 100 * time.Millisecond, + tmc: &testutil.TabletManagerClient{ + SetReadOnlyResults: map[string]error{ + "zone-1-0000000100": nil, + }, + SetReadOnlyDelays: map[string]time.Duration{ + "zone-1-0000000100": 200 * time.Millisecond, + }, + }, + errShouldContain: "context deadline exceeded", + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + oldTmc := tmc + oldRemoteOpTimeout := topo.RemoteOperationTimeout + defer func() { + tmc = oldTmc + topo.RemoteOperationTimeout = oldRemoteOpTimeout + }() + + tmc = tt.tmc + if tt.remoteOpTimeout != 0 { + topo.RemoteOperationTimeout = tt.remoteOpTimeout + } + + err := setReadOnly(context.Background(), tt.tablet) + if tt.errShouldContain == "" { + require.NoError(t, err) + return + } + require.ErrorContains(t, err, tt.errShouldContain) + }) + } +} + +func TestTabletUndoDemotePrimary(t *testing.T) { + tests := []struct { + name string + tablet *topodatapb.Tablet + tmc *testutil.TabletManagerClient + remoteOpTimeout time.Duration + errShouldContain string + }{ + { + name: "Success", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + UndoDemotePrimaryResults: map[string]error{ + "zone-1-0000000100": nil, + }, + }, + }, { + name: "Failure", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + UndoDemotePrimaryResults: map[string]error{ + "zone-1-0000000100": fmt.Errorf("testing error"), + }, + }, + errShouldContain: "testing error", + }, { + name: "Timeout", + tablet: tab100, + remoteOpTimeout: 100 * time.Millisecond, + tmc: &testutil.TabletManagerClient{ + UndoDemotePrimaryResults: map[string]error{ + "zone-1-0000000100": nil, + }, + UndoDemotePrimaryDelays: map[string]time.Duration{ + "zone-1-0000000100": 200 * time.Millisecond, + }, + }, + errShouldContain: "context deadline exceeded", + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + oldTmc := tmc + oldRemoteOpTimeout := topo.RemoteOperationTimeout + defer func() { + tmc = oldTmc + topo.RemoteOperationTimeout = oldRemoteOpTimeout + }() + + tmc = tt.tmc + if tt.remoteOpTimeout != 0 { + topo.RemoteOperationTimeout = tt.remoteOpTimeout + } + + err := tabletUndoDemotePrimary(context.Background(), tt.tablet, false) + if tt.errShouldContain == "" { + require.NoError(t, err) + return + } + require.ErrorContains(t, err, tt.errShouldContain) + }) + } +} + +func TestChangeTabletType(t *testing.T) { + tests := []struct { + name string + tablet *topodatapb.Tablet + tmc *testutil.TabletManagerClient + remoteOpTimeout time.Duration + errShouldContain string + }{ + { + name: "Success", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + ChangeTabletTypeResult: map[string]error{ + "zone-1-0000000100": nil, + }, + }, + }, { + name: "Failure", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + ChangeTabletTypeResult: map[string]error{ + "zone-1-0000000100": fmt.Errorf("testing error"), + }, + }, + errShouldContain: "testing error", + }, { + name: "Timeout", + tablet: tab100, + remoteOpTimeout: 100 * time.Millisecond, + tmc: &testutil.TabletManagerClient{ + ChangeTabletTypeResult: map[string]error{ + "zone-1-0000000100": nil, + }, + ChangeTabletTypeDelays: map[string]time.Duration{ + "zone-1-0000000100": 200 * time.Millisecond, + }, + }, + errShouldContain: "context deadline exceeded", + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + oldTmc := tmc + oldRemoteOpTimeout := topo.RemoteOperationTimeout + defer func() { + tmc = oldTmc + topo.RemoteOperationTimeout = oldRemoteOpTimeout + }() + + tmc = tt.tmc + if tt.remoteOpTimeout != 0 { + topo.RemoteOperationTimeout = tt.remoteOpTimeout + } + + err := changeTabletType(context.Background(), tt.tablet, topodatapb.TabletType_REPLICA, false) + if tt.errShouldContain == "" { + require.NoError(t, err) + return + } + require.ErrorContains(t, err, tt.errShouldContain) + }) + } +} + +func TestSetReplicationSource(t *testing.T) { + tests := []struct { + name string + tablet *topodatapb.Tablet + tmc *testutil.TabletManagerClient + remoteOpTimeout time.Duration + errShouldContain string + }{ + { + name: "Success", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + SetReplicationSourceResults: map[string]error{ + "zone-1-0000000100": nil, + }, + }, + }, { + name: "Failure", + tablet: tab100, + tmc: &testutil.TabletManagerClient{ + SetReplicationSourceResults: map[string]error{ + "zone-1-0000000100": fmt.Errorf("testing error"), + }, + }, + errShouldContain: "testing error", + }, { + name: "Timeout", + tablet: tab100, + remoteOpTimeout: 100 * time.Millisecond, + tmc: &testutil.TabletManagerClient{ + SetReplicationSourceResults: map[string]error{ + "zone-1-0000000100": nil, + }, + SetReplicationSourceDelays: map[string]time.Duration{ + "zone-1-0000000100": 200 * time.Millisecond, + }, + }, + errShouldContain: "context deadline exceeded", + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + oldTmc := tmc + oldRemoteOpTimeout := topo.RemoteOperationTimeout + defer func() { + tmc = oldTmc + topo.RemoteOperationTimeout = oldRemoteOpTimeout + }() + + tmc = tt.tmc + if tt.remoteOpTimeout != 0 { + topo.RemoteOperationTimeout = tt.remoteOpTimeout + } + + err := setReplicationSource(context.Background(), tt.tablet, tab101, false) + if tt.errShouldContain == "" { + require.NoError(t, err) + return + } + require.ErrorContains(t, err, tt.errShouldContain) + }) + } +} diff --git a/go/vt/vttest/topoctl.go b/go/vt/vttest/topoctl.go index 2b63900d6d8..1fd4cb6e101 100644 --- a/go/vt/vttest/topoctl.go +++ b/go/vt/vttest/topoctl.go @@ -31,6 +31,7 @@ func (ctl *Topoctl) Setup() error { if err != nil { return err } + defer topoServer.Close() log.Infof("Creating cells if they don't exist in the provided topo server %s %s %s", ctl.TopoImplementation, ctl.TopoGlobalServerAddress, ctl.TopoGlobalRoot) // Create cells if it doesn't exist to be idempotent. Should work when we share the same topo server across multiple local clusters. diff --git a/test.go b/test.go index d63bed334c4..f8274d2823f 100755 --- a/test.go +++ b/test.go @@ -77,7 +77,7 @@ For example: // Flags var ( flavor = flag.String("flavor", "mysql57", "comma-separated bootstrap flavor(s) to run against (when using Docker mode). Available flavors: all,"+flavors) - bootstrapVersion = flag.String("bootstrap-version", "27.3", "the version identifier to use for the docker images") + bootstrapVersion = flag.String("bootstrap-version", "27.5", "the version identifier to use for the docker images") runCount = flag.Int("runs", 1, "run each test this many times") retryMax = flag.Int("retry", 3, "max number of retries, to detect flaky tests") logPass = flag.Bool("log-pass", false, "log test output even if it passes") diff --git a/test/templates/cluster_endtoend_test.tpl b/test/templates/cluster_endtoend_test.tpl index 526cb04da67..9e2f3b6e89f 100644 --- a/test/templates/cluster_endtoend_test.tpl +++ b/test/templates/cluster_endtoend_test.tpl @@ -14,7 +14,8 @@ env: jobs: build: name: Run endtoend tests on {{.Name}} - runs-on: {{if .Cores16}}gh-hosted-runners-16cores-1{{else}}gh-hosted-runners-4cores-1{{end}} + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -28,9 +29,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "{{"${{github.event.pull_request}}"}}" == "" ]] && [[ "{{"${{github.ref}}"}}" != "refs/heads/main" ]] && [[ ! "{{"${{github.ref}}"}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "{{"${{github.ref}}"}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -74,7 +72,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/test/templates/cluster_endtoend_test_docker.tpl b/test/templates/cluster_endtoend_test_docker.tpl index 650fc81a57a..abc9b79286b 100644 --- a/test/templates/cluster_endtoend_test_docker.tpl +++ b/test/templates/cluster_endtoend_test_docker.tpl @@ -6,7 +6,8 @@ permissions: read-all jobs: build: name: Run endtoend tests on {{.Name}} - runs-on: {{if .Cores16}}gh-hosted-runners-16cores-1{{else}}gh-hosted-runners-4cores-1{{end}} + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -20,9 +21,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "{{"${{github.event.pull_request}}"}}" == "" ]] && [[ "{{"${{github.ref}}"}}" != "refs/heads/main" ]] && [[ ! "{{"${{github.ref}}"}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "{{"${{github.ref}}"}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -56,7 +54,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Tune the OS if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' diff --git a/test/templates/cluster_endtoend_test_mysql57.tpl b/test/templates/cluster_endtoend_test_mysql57.tpl index a2a23941f76..09a43c1b76a 100644 --- a/test/templates/cluster_endtoend_test_mysql57.tpl +++ b/test/templates/cluster_endtoend_test_mysql57.tpl @@ -19,7 +19,8 @@ env: jobs: build: name: Run endtoend tests on {{.Name}} - runs-on: {{if .Cores16}}gh-hosted-runners-16cores-1{{else}}gh-hosted-runners-4cores-1{{end}} + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -33,9 +34,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "{{"${{github.event.pull_request}}"}}" == "" ]] && [[ "{{"${{github.ref}}"}}" != "refs/heads/main" ]] && [[ ! "{{"${{github.ref}}"}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "{{"${{github.ref}}"}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -79,7 +77,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.end_to_end == 'true' @@ -134,6 +132,7 @@ jobs: wget "https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_all.deb" sudo apt-get install -y gnupg2 sudo dpkg -i "percona-release_latest.$(lsb_release -sc)_all.deb" + sudo percona-release enable-only pxb-24 sudo apt-get update if [[ -n $XTRABACKUP_VERSION ]]; then debfile="percona-xtrabackup-24_$XTRABACKUP_VERSION.$(lsb_release -sc)_amd64.deb" diff --git a/test/templates/cluster_endtoend_test_self_hosted.tpl b/test/templates/cluster_endtoend_test_self_hosted.tpl index e28de83004e..679b9a9437e 100644 --- a/test/templates/cluster_endtoend_test_self_hosted.tpl +++ b/test/templates/cluster_endtoend_test_self_hosted.tpl @@ -9,7 +9,8 @@ permissions: read-all jobs: build: name: Run endtoend tests on {{.Name}} - runs-on: self-hosted + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -23,9 +24,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "{{"${{github.event.pull_request}}"}}" == "" ]] && [[ "{{"${{github.ref}}"}}" != "refs/heads/main" ]] && [[ ! "{{"${{github.ref}}"}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "{{"${{github.ref}}"}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT diff --git a/test/templates/dockerfile.tpl b/test/templates/dockerfile.tpl index af27966f814..e3207bd06b8 100644 --- a/test/templates/dockerfile.tpl +++ b/test/templates/dockerfile.tpl @@ -1,4 +1,4 @@ -ARG bootstrap_version=27.3 +ARG bootstrap_version=27.5 ARG image="vitess/bootstrap:${bootstrap_version}-{{.Platform}}" FROM "${image}" @@ -15,6 +15,7 @@ RUN wget https://repo.percona.com/apt/percona-release_latest.$(lsb_release -sc)_ RUN apt-get update RUN apt-get install -y gnupg2 RUN dpkg -i percona-release_latest.$(lsb_release -sc)_all.deb +RUN percona-release enable-only pxb-24 RUN apt-get update RUN apt-get install -y percona-xtrabackup-24 {{end}} diff --git a/test/templates/unit_test.tpl b/test/templates/unit_test.tpl index 4179c362d3e..25928f7041d 100644 --- a/test/templates/unit_test.tpl +++ b/test/templates/unit_test.tpl @@ -14,7 +14,8 @@ env: jobs: test: name: {{.Name}} - runs-on: gh-hosted-runners-4cores-1 + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -28,9 +29,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "{{"${{github.event.pull_request}}"}}" == "" ]] && [[ "{{"${{github.ref}}"}}" != "refs/heads/main" ]] && [[ ! "{{"${{github.ref}}"}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "{{"${{github.ref}}"}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT @@ -69,7 +67,7 @@ jobs: if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' uses: actions/setup-go@v5 with: - go-version: 1.22.3 + go-version: 1.22.5 - name: Set up python if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.unit_tests == 'true' diff --git a/test/templates/unit_test_self_hosted.tpl b/test/templates/unit_test_self_hosted.tpl index c6d6790fbfb..d8cd56a9c22 100644 --- a/test/templates/unit_test_self_hosted.tpl +++ b/test/templates/unit_test_self_hosted.tpl @@ -8,7 +8,8 @@ permissions: read-all jobs: test: - runs-on: self-hosted + runs-on: + group: vitess-ubuntu20 steps: - name: Skip CI @@ -22,9 +23,6 @@ jobs: id: skip-workflow run: | skip='false' - if [[ "{{"${{github.event.pull_request}}"}}" == "" ]] && [[ "{{"${{github.ref}}"}}" != "refs/heads/main" ]] && [[ ! "{{"${{github.ref}}"}}" =~ ^refs/heads/release-[0-9]+\.[0-9]$ ]] && [[ ! "{{"${{github.ref}}"}}" =~ "refs/tags/.*" ]]; then - skip='true' - fi echo Skip ${skip} echo "skip-workflow=${skip}" >> $GITHUB_OUTPUT diff --git a/tools/get_previous_release.sh b/tools/get_previous_release.sh index 64988099c56..9b33df58dfc 100755 --- a/tools/get_previous_release.sh +++ b/tools/get_previous_release.sh @@ -20,25 +20,7 @@ # github.base_ref $1 -target_release="" +# force previous release to v15 +target_release="slack-15.0" -base_release_branch=$(echo "$1" | grep -E 'release-[0-9]*.0$') -if [ "$base_release_branch" == "" ]; then - base_release_branch=$(echo "$2" | grep -E 'release-[0-9]*.0$') -fi -if [ "$base_release_branch" != "" ]; then - major_release=$(echo "$base_release_branch" | sed 's/release-*//' | sed 's/\.0//') - target_major_release=$((major_release-1)) - target_release_number=$(git show-ref --tags | grep -E 'refs/tags/v[0-9]*.[0-9]*.[0-9]*$' | sed 's/[a-z0-9]* refs\/tags\/v//' | awk -v FS=. -v RELEASE="$target_major_release" '{if ($1 == RELEASE) print; }' | sort -nr | head -n1) - target_release="v$target_release_number" -else - target_major_release=$(git show-ref | grep -E 'refs/remotes/origin/release-[0-9]*\.0$' | sed 's/[a-z0-9]* refs\/remotes\/origin\/release-//' | sed 's/\.0//' | sort -nr | head -n1) - target_release_number=$(git show-ref --tags | grep -E 'refs/tags/v[0-9]*.[0-9]*.[0-9]*$' | sed 's/[a-z0-9]* refs\/tags\/v//' | awk -v FS=. -v RELEASE="$target_major_release" '{if ($1 == RELEASE) print; }' | sort -nr | head -n1) - target_release="v$target_release_number" - if [ -z "$target_release_number" ] - then - target_release="release-$target_major_release.0" - fi -fi - -echo "$target_release" \ No newline at end of file +echo "$target_release"