Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ddl: abstract decode job args v1 #56420

Merged
merged 11 commits into from
Oct 8, 2024
Merged

Conversation

D3Hunter
Copy link
Contributor

What problem does this PR solve?

Issue Number: ref #53930

Problem Summary:

What changed and how does it work?

add decodeV1 to JobArgs, adjust other fillJobV1 to return args directly

Check List

Tests

  • Unit test, existing tests should cover it
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Sep 30, 2024
Copy link

tiprow bot commented Sep 30, 2024

Hi @D3Hunter. Thanks for your PR.

PRs from untrusted users cannot be marked as trusted with /ok-to-test in this repo meaning untrusted PR authors can never trigger tests themselves. Collaborators can still trigger tests on the PR using /test all.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link

codecov bot commented Sep 30, 2024

Codecov Report

Attention: Patch coverage is 92.51497% with 25 lines in your changes missing coverage. Please review.

Project coverage is 76.2126%. Comparing base (7daf026) to head (1523bd4).
Report is 14 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #56420        +/-   ##
================================================
+ Coverage   73.3685%   76.2126%   +2.8441%     
================================================
  Files          1624       1648        +24     
  Lines        448117     457828      +9711     
================================================
+ Hits         328777     348923     +20146     
+ Misses        99198      87289     -11909     
- Partials      20142      21616      +1474     
Flag Coverage Δ
integration 52.0044% <25.7485%> (?)
unit 72.6017% <92.5149%> (+0.1409%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 52.9478% <ø> (ø)
parser ∅ <ø> (∅)
br 63.4305% <ø> (+17.9175%) ⬆️

@D3Hunter D3Hunter added the ok-to-test Indicates a PR is ready to be tested. label Sep 30, 2024
@D3Hunter
Copy link
Contributor Author

/test fast_test_tiprow_ddlargsv1
/test pull-unit-test-ddlv1

Copy link

tiprow bot commented Sep 30, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test fast_test_tiprow_ddlargsv1
  • /test tidb_parser_test

Use /test all to run the following jobs that were automatically triggered:

  • fast_test_tiprow
  • tidb_parser_test

In response to this:

/test fast_test_tiprow_ddlargsv1
/test pull-unit-test-ddlv1

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@D3Hunter
Copy link
Contributor Author

/test fast_test_tiprow_ddlargsv1

Copy link

ti-chi-bot bot commented Sep 30, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test build
  • /test check-dev
  • /test check-dev2
  • /test mysql-test
  • /test pull-br-integration-test
  • /test pull-integration-ddl-test
  • /test pull-lightning-integration-test
  • /test pull-mysql-client-test
  • /test unit-test

The following commands are available to trigger optional jobs:

  • /test pingcap/tidb/canary_ghpr_unit_test
  • /test pull-common-test
  • /test pull-e2e-test
  • /test pull-integration-common-test
  • /test pull-integration-copr-test
  • /test pull-integration-jdbc-test
  • /test pull-integration-mysql-test
  • /test pull-integration-nodejs-test
  • /test pull-sqllogic-test
  • /test pull-tiflash-test
  • /test pull-unit-test-ddlv1

Use /test all to run the following jobs that were automatically triggered:

  • pingcap/tidb/ghpr_build
  • pingcap/tidb/ghpr_check
  • pingcap/tidb/ghpr_check2
  • pingcap/tidb/ghpr_mysql_test
  • pingcap/tidb/ghpr_unit_test
  • pingcap/tidb/pull_br_integration_test
  • pingcap/tidb/pull_integration_ddl_test
  • pingcap/tidb/pull_lightning_integration_test
  • pingcap/tidb/pull_mysql_client_test

In response to this:

/test fast_test_tiprow_ddlargsv1

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@D3Hunter
Copy link
Contributor Author

/retest

@D3Hunter
Copy link
Contributor Author

/test pull-unit-test-ddlv1

Copy link

tiprow bot commented Sep 30, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test fast_test_tiprow_ddlargsv1
  • /test tidb_parser_test

Use /test all to run the following jobs that were automatically triggered:

  • fast_test_tiprow
  • tidb_parser_test

In response to this:

/test pull-unit-test-ddlv1

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@D3Hunter
Copy link
Contributor Author

/retest

@D3Hunter
Copy link
Contributor Author

/test fast_test_tiprow_ddlargsv1
/test pull-unit-test-ddlv1

Copy link

tiprow bot commented Sep 30, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test fast_test_tiprow_ddlargsv1
  • /test tidb_parser_test

Use /test all to run the following jobs that were automatically triggered:

  • fast_test_tiprow
  • tidb_parser_test

In response to this:

/test fast_test_tiprow_ddlargsv1
/test pull-unit-test-ddlv1

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@D3Hunter
Copy link
Contributor Author

/test fast_test_tiprow_ddlargsv1

Copy link

ti-chi-bot bot commented Sep 30, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test build
  • /test check-dev
  • /test check-dev2
  • /test mysql-test
  • /test pull-br-integration-test
  • /test pull-integration-ddl-test
  • /test pull-lightning-integration-test
  • /test pull-mysql-client-test
  • /test unit-test

The following commands are available to trigger optional jobs:

  • /test pingcap/tidb/canary_ghpr_unit_test
  • /test pull-common-test
  • /test pull-e2e-test
  • /test pull-integration-common-test
  • /test pull-integration-copr-test
  • /test pull-integration-jdbc-test
  • /test pull-integration-mysql-test
  • /test pull-integration-nodejs-test
  • /test pull-sqllogic-test
  • /test pull-tiflash-test
  • /test pull-unit-test-ddlv1

Use /test all to run the following jobs that were automatically triggered:

  • pingcap/tidb/ghpr_build
  • pingcap/tidb/ghpr_check
  • pingcap/tidb/ghpr_check2
  • pingcap/tidb/ghpr_mysql_test
  • pingcap/tidb/ghpr_unit_test
  • pingcap/tidb/pull_br_integration_test
  • pingcap/tidb/pull_integration_ddl_test
  • pingcap/tidb/pull_lightning_integration_test
  • pingcap/tidb/pull_mysql_client_test

In response to this:

/test fast_test_tiprow_ddlargsv1

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@D3Hunter
Copy link
Contributor Author

/retest

}
intest.Assert(job.Type == ActionDropPlacementPolicy, "Invalid job type for PlacementPolicyArgs")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about returning the error instead? If job.Type is not one of ActionCreatePlacementPolicy, ActionAlterPlacementPolicy or ActionDropPlacementPolicy, it should return an error in non-test environment.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can remove it actually, only 3 job types share this Args struct

pkg/meta/model/job_args.go Outdated Show resolved Hide resolved
@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Oct 8, 2024
Copy link

ti-chi-bot bot commented Oct 8, 2024

@joechenrh: adding LGTM is restricted to approvers and reviewers in OWNERS files.

In response to this:

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link

ti-chi-bot bot commented Oct 8, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: joechenrh, tangenta, wjhuang2016

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Oct 8, 2024
Copy link

ti-chi-bot bot commented Oct 8, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-10-08 06:28:12.780134426 +0000 UTC m=+941048.200347438: ☑️ agreed by tangenta.
  • 2024-10-08 06:54:12.411861614 +0000 UTC m=+942607.832074626: ☑️ agreed by wjhuang2016.

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/test pull-unit-test-ddlv1

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/test fast_test_tiprow_ddl

Copy link

ti-chi-bot bot commented Oct 8, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test build
  • /test check-dev
  • /test check-dev2
  • /test mysql-test
  • /test pull-br-integration-test
  • /test pull-integration-ddl-test
  • /test pull-lightning-integration-test
  • /test pull-mysql-client-test
  • /test unit-test

The following commands are available to trigger optional jobs:

  • /test pingcap/tidb/canary_ghpr_unit_test
  • /test pull-common-test
  • /test pull-e2e-test
  • /test pull-integration-common-test
  • /test pull-integration-copr-test
  • /test pull-integration-jdbc-test
  • /test pull-integration-mysql-test
  • /test pull-integration-nodejs-test
  • /test pull-sqllogic-test
  • /test pull-tiflash-test
  • /test pull-unit-test-ddlv1

Use /test all to run the following jobs that were automatically triggered:

  • pingcap/tidb/ghpr_build
  • pingcap/tidb/ghpr_check
  • pingcap/tidb/ghpr_check2
  • pingcap/tidb/ghpr_mysql_test
  • pingcap/tidb/ghpr_unit_test
  • pingcap/tidb/pull_br_integration_test
  • pingcap/tidb/pull_integration_ddl_test
  • pingcap/tidb/pull_lightning_integration_test
  • pingcap/tidb/pull_mysql_client_test

In response to this:

/test fast_test_tiprow_ddl

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link

tiprow bot commented Oct 8, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test fast_test_tiprow_ddlargsv1
  • /test tidb_parser_test

Use /test all to run the following jobs that were automatically triggered:

  • fast_test_tiprow
  • tidb_parser_test

In response to this:

/test pull-unit-test-ddlv1

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link

tiprow bot commented Oct 8, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test fast_test_tiprow_ddlargsv1
  • /test tidb_parser_test

Use /test all to run the following jobs that were automatically triggered:

  • fast_test_tiprow
  • tidb_parser_test

In response to this:

/test fast_test_tiprow_ddl

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/test fast_test_tiprow_ddl

Copy link

ti-chi-bot bot commented Oct 8, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test build
  • /test check-dev
  • /test check-dev2
  • /test mysql-test
  • /test pull-br-integration-test
  • /test pull-integration-ddl-test
  • /test pull-lightning-integration-test
  • /test pull-mysql-client-test
  • /test unit-test

The following commands are available to trigger optional jobs:

  • /test pingcap/tidb/canary_ghpr_unit_test
  • /test pull-common-test
  • /test pull-e2e-test
  • /test pull-integration-common-test
  • /test pull-integration-copr-test
  • /test pull-integration-jdbc-test
  • /test pull-integration-mysql-test
  • /test pull-integration-nodejs-test
  • /test pull-sqllogic-test
  • /test pull-tiflash-test
  • /test pull-unit-test-ddlv1

Use /test all to run the following jobs that were automatically triggered:

  • pingcap/tidb/ghpr_build
  • pingcap/tidb/ghpr_check
  • pingcap/tidb/ghpr_check2
  • pingcap/tidb/ghpr_mysql_test
  • pingcap/tidb/ghpr_unit_test
  • pingcap/tidb/pull_br_integration_test
  • pingcap/tidb/pull_integration_ddl_test
  • pingcap/tidb/pull_lightning_integration_test
  • pingcap/tidb/pull_mysql_client_test

In response to this:

/test fast_test_tiprow_ddl

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link

tiprow bot commented Oct 8, 2024

@D3Hunter: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test fast_test_tiprow_ddlargsv1
  • /test tidb_parser_test

Use /test all to run the following jobs that were automatically triggered:

  • fast_test_tiprow
  • tidb_parser_test

In response to this:

/test fast_test_tiprow_ddl

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/retest

4 similar comments
@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/retest

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/retest

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/retest

@D3Hunter
Copy link
Contributor Author

D3Hunter commented Oct 8, 2024

/retest

@ti-chi-bot ti-chi-bot bot merged commit 6122947 into pingcap:master Oct 8, 2024
25 of 26 checks passed
@D3Hunter D3Hunter deleted the abstract-decodev1 branch October 8, 2024 15:10
breezewish added a commit to winoros/tidb that referenced this pull request Oct 9, 2024
* origin/master:
  ddl: Stabilized TestRemovePartitioningAutoIDs test. (pingcap#56436)
  execdetails: Display vector search info in EXPLAIN ANALYZE (pingcap#56478)
  ddl: abstract decode job args v1 (pingcap#56420)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm ok-to-test Indicates a PR is ready to be tested. release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants