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

TiFlash support TiDB push down ExtraPhysTblID column #4203

Merged
merged 11 commits into from
Mar 11, 2022

Conversation

hehechen
Copy link
Contributor

@hehechen hehechen commented Mar 8, 2022

What problem does this PR solve?

Issue Number: close #4180

What is changed and how it works?

In readImpl method of DMSegmentThreadInputStream, insert ExtraPhysTblID colunm in the block at the same position as the ExtraPhysTblID column in column_names parameter in the StorageDeltaMerge::read function.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

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

TiFlash support TiDB push down ExtraPhysTblID column.

Signed-off-by: hehechen <awd123456sss@gmail.com>
Signed-off-by: hehechen <awd123456sss@gmail.com>
Signed-off-by: hehechen <awd123456sss@gmail.com>
Signed-off-by: hehechen <awd123456sss@gmail.com>
@ti-chi-bot
Copy link
Member

ti-chi-bot commented Mar 8, 2022

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • flowbehappy
  • windtalker

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

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

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added do-not-merge/needs-linked-issue release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed do-not-merge/needs-linked-issue release-note-none Denotes a PR that doesn't merit a release note. labels Mar 8, 2022
@hehechen hehechen changed the title TiFlash support TiDB push down TExtraPhysTblID column TiFlash support TiDB push down ExtraPhysTblID column Mar 9, 2022
Signed-off-by: hehechen <awd123456sss@gmail.com>
@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-all-tests

@sre-bot
Copy link
Collaborator

sre-bot commented Mar 9, 2022

Coverage for changed files

Filename                                                       Regions    Missed Regions     Cover   Functions  Missed Functions  Executed       Lines      Missed Lines     Cover    Branches   Missed Branches     Cover
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Flash/Coprocessor/DAGStorageInterpreter.cpp                        272               272     0.00%          15                15     0.00%         499               499     0.00%         170               170     0.00%
Storages/DeltaMerge/DMSegmentThreadInputStream.h                    62                 6    90.32%           5                 0   100.00%          73                 2    97.26%          28                 8    71.43%
Storages/DeltaMerge/DeltaMergeDefines.h                             26                 0   100.00%           8                 0   100.00%          28                 0   100.00%           2                 0   100.00%
Storages/DeltaMerge/DeltaMergeStore.cpp                           1278               426    66.67%          65                 5    92.31%        1863               409    78.05%         746               348    53.35%
Storages/DeltaMerge/DeltaMergeStore.h                               41                13    68.29%          19                 2    89.47%          85                30    64.71%          42                11    73.81%
Storages/DeltaMerge/tests/gtest_dm_storage_delta_merge.cpp        1489               285    80.86%          14                 0   100.00%         540                 8    98.52%         472               223    52.75%
Storages/ITableDeclaration.cpp                                      94                88     6.38%          17                15    11.76%         189               181     4.23%          70                68     2.86%
Storages/MutableSupport.h                                           17                17     0.00%          10                10     0.00%          37                37     0.00%           6                 6     0.00%
Storages/PrimaryKeyNotMatchException.h                               1                 1     0.00%           1                 1     0.00%           1                 1     0.00%           0                 0         -
Storages/StorageDeltaMerge.cpp                                     667               358    46.33%          56                29    48.21%        1290               762    40.93%         376               257    31.65%
Storages/StorageDeltaMerge.h                                        11                 7    36.36%          11                 7    36.36%          15                 9    40.00%           0                 0         -
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                                             3958              1473    62.78%         221                84    61.99%        4620              1938    58.05%        1912              1091    42.94%

Coverage summary

Functions  MissedFunctions  Executed  Lines   MissedLines  Cover
16706      9453             43.42%    187321  95569        48.98%

full coverage report (for internal network access only)

Signed-off-by: hehechen <awd123456sss@gmail.com>
@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-integration-test

1 similar comment
@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-integration-test

@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-integration-test

Copy link
Contributor

@windtalker windtalker left a comment

Choose a reason for hiding this comment

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

Changes in DAGStorageInterpreter LGTM

@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-integration-test

Signed-off-by: hehechen <awd123456sss@gmail.com>
@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-integration-test

Signed-off-by: hehechen <awd123456sss@gmail.com>
@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-all-tests

@sre-bot
Copy link
Collaborator

sre-bot commented Mar 9, 2022

Coverage for changed files

Filename                                                       Regions    Missed Regions     Cover   Functions  Missed Functions  Executed       Lines      Missed Lines     Cover    Branches   Missed Branches     Cover
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Flash/Coprocessor/DAGStorageInterpreter.cpp                        272               272     0.00%          15                15     0.00%         499               499     0.00%         170               170     0.00%
Storages/DeltaMerge/DMSegmentThreadInputStream.h                    62                 6    90.32%           5                 0   100.00%          73                 2    97.26%          28                 8    71.43%
Storages/DeltaMerge/DeltaMergeDefines.h                             26                 0   100.00%           8                 0   100.00%          28                 0   100.00%           2                 0   100.00%
Storages/DeltaMerge/DeltaMergeStore.cpp                           1278               435    65.96%          65                 5    92.31%        1863               413    77.83%         746               351    52.95%
Storages/DeltaMerge/DeltaMergeStore.h                               41                13    68.29%          19                 2    89.47%          85                30    64.71%          42                11    73.81%
Storages/DeltaMerge/tests/gtest_dm_storage_delta_merge.cpp        1489               285    80.86%          14                 0   100.00%         540                 8    98.52%         472               223    52.75%
Storages/ITableDeclaration.cpp                                      92                87     5.43%          18                15    16.67%         182               172     5.49%          68                67     1.47%
Storages/ITableDeclaration.h                                         3                 1    66.67%           3                 1    66.67%           5                 3    40.00%           0                 0         -
Storages/MutableSupport.h                                           17                17     0.00%          10                10     0.00%          37                37     0.00%           6                 6     0.00%
Storages/PrimaryKeyNotMatchException.h                               1                 1     0.00%           1                 1     0.00%           1                 1     0.00%           0                 0         -
Storages/StorageDeltaMerge.cpp                                     667               358    46.33%          56                29    48.21%        1290               762    40.93%         376               257    31.65%
Storages/StorageDeltaMerge.h                                        11                 7    36.36%          11                 7    36.36%          15                 9    40.00%           0                 0         -
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                                             3959              1482    62.57%         225                85    62.22%        4618              1936    58.08%        1910              1093    42.77%

Coverage summary

Functions  MissedFunctions  Executed  Lines   MissedLines  Cover
16707      9453             43.42%    187314  95557        48.99%

full coverage report (for internal network access only)

@hehechen
Copy link
Contributor Author

hehechen commented Mar 9, 2022

/run-integration-test

@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Mar 9, 2022
Signed-off-by: hehechen <awd123456sss@gmail.com>
Copy link
Contributor

@windtalker windtalker left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Mar 10, 2022
@hehechen
Copy link
Contributor Author

/run-integration-tests

@hehechen
Copy link
Contributor Author

/merge

@ti-chi-bot
Copy link
Member

@hehechen: It seems you want to merge this PR, I will help you trigger all the tests:

/run-all-tests

You only need to trigger /merge once, and if the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

If you have any questions about the PR merge process, please refer to pr process.

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 ti-community-infra/tichi repository.

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: 8ab8f73

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Mar 11, 2022
@sre-bot
Copy link
Collaborator

sre-bot commented Mar 11, 2022

Coverage for changed files

Filename                                                       Regions    Missed Regions     Cover   Functions  Missed Functions  Executed       Lines      Missed Lines     Cover    Branches   Missed Branches     Cover
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Flash/Coprocessor/DAGStorageInterpreter.cpp                        272               272     0.00%          15                15     0.00%         499               499     0.00%         170               170     0.00%
Storages/DeltaMerge/DMSegmentThreadInputStream.h                    62                 6    90.32%           5                 0   100.00%          73                 2    97.26%          28                 8    71.43%
Storages/DeltaMerge/DeltaMergeDefines.h                             26                 0   100.00%           8                 0   100.00%          28                 0   100.00%           2                 0   100.00%
Storages/DeltaMerge/DeltaMergeStore.cpp                           1317               466    64.62%          65                 5    92.31%        1885               426    77.40%         766               366    52.22%
Storages/DeltaMerge/DeltaMergeStore.h                               41                13    68.29%          19                 2    89.47%          85                30    64.71%          42                11    73.81%
Storages/DeltaMerge/tests/gtest_dm_storage_delta_merge.cpp        1489               285    80.86%          14                 0   100.00%         540                 8    98.52%         472               223    52.75%
Storages/ITableDeclaration.cpp                                      92                87     5.43%          18                15    16.67%         182               172     5.49%          68                67     1.47%
Storages/ITableDeclaration.h                                         3                 1    66.67%           3                 1    66.67%           5                 3    40.00%           0                 0         -
Storages/MutableSupport.h                                           17                17     0.00%          10                10     0.00%          37                37     0.00%           6                 6     0.00%
Storages/PrimaryKeyNotMatchException.h                               1                 1     0.00%           1                 1     0.00%           1                 1     0.00%           0                 0         -
Storages/StorageDeltaMerge.cpp                                     667               358    46.33%          56                29    48.21%        1290               762    40.93%         376               257    31.65%
Storages/StorageDeltaMerge.h                                        11                 7    36.36%          11                 7    36.36%          15                 9    40.00%           0                 0         -
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                                             3998              1513    62.16%         225                85    62.22%        4640              1949    58.00%        1930              1108    42.59%

Coverage summary

Functions  MissedFunctions  Executed  Lines   MissedLines  Cover
16781      9444             43.72%    189056  95724        49.37%

full coverage report (for internal network access only)

@ti-chi-bot
Copy link
Member

@hehechen: Your PR was out of date, I have automatically updated it for you.

At the same time I will also trigger all tests for you:

/run-all-tests

If the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

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 ti-community-infra/tichi repository.

@sre-bot
Copy link
Collaborator

sre-bot commented Mar 11, 2022

Coverage for changed files

Filename                                                       Regions    Missed Regions     Cover   Functions  Missed Functions  Executed       Lines      Missed Lines     Cover    Branches   Missed Branches     Cover
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Flash/Coprocessor/DAGStorageInterpreter.cpp                        272               272     0.00%          15                15     0.00%         499               499     0.00%         170               170     0.00%
Storages/DeltaMerge/DMSegmentThreadInputStream.h                    62                 6    90.32%           5                 0   100.00%          73                 2    97.26%          28                 8    71.43%
Storages/DeltaMerge/DeltaMergeDefines.h                             26                 0   100.00%           8                 0   100.00%          28                 0   100.00%           2                 0   100.00%
Storages/DeltaMerge/DeltaMergeStore.cpp                           1317               466    64.62%          65                 5    92.31%        1885               426    77.40%         766               366    52.22%
Storages/DeltaMerge/DeltaMergeStore.h                               41                13    68.29%          19                 2    89.47%          85                30    64.71%          42                11    73.81%
Storages/DeltaMerge/tests/gtest_dm_storage_delta_merge.cpp        1489               285    80.86%          14                 0   100.00%         540                 8    98.52%         472               223    52.75%
Storages/ITableDeclaration.cpp                                      92                87     5.43%          18                15    16.67%         182               172     5.49%          68                67     1.47%
Storages/ITableDeclaration.h                                         3                 1    66.67%           3                 1    66.67%           5                 3    40.00%           0                 0         -
Storages/MutableSupport.h                                           17                17     0.00%          10                10     0.00%          37                37     0.00%           6                 6     0.00%
Storages/PrimaryKeyNotMatchException.h                               1                 1     0.00%           1                 1     0.00%           1                 1     0.00%           0                 0         -
Storages/StorageDeltaMerge.cpp                                     667               358    46.33%          56                29    48.21%        1290               762    40.93%         376               257    31.65%
Storages/StorageDeltaMerge.h                                        11                 7    36.36%          11                 7    36.36%          15                 9    40.00%           0                 0         -
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                                             3998              1513    62.16%         225                85    62.22%        4640              1949    58.00%        1930              1108    42.59%

Coverage summary

Functions  MissedFunctions  Executed  Lines   MissedLines  Cover
16781      9444             43.72%    189076  95747        49.36%

full coverage report (for internal network access only)

@ti-chi-bot ti-chi-bot merged commit e8fae73 into pingcap:master Mar 11, 2022
@JaySon-Huang JaySon-Huang deleted the extraphystblid branch March 11, 2022 08:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support virtual column ExtraPhysTblID in TableScan
5 participants