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: enable the ddl notifier by default #56864

Merged

Conversation

Rustin170506
Copy link
Member

@Rustin170506 Rustin170506 commented Oct 28, 2024

What problem does this PR solve?

Issue Number: ref #55722

Problem Summary:

What changed and how does it work?

Enable the DDL notifier by default.
I added the DDLNotifierTableVersion to init the DDL notifier table.

Check List

Tests

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/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 28, 2024
Copy link

codecov bot commented Oct 28, 2024

Codecov Report

Attention: Patch coverage is 75.67568% with 9 lines in your changes missing coverage. Please review.

Project coverage is 57.2836%. Comparing base (c550aae) to head (d2a718b).
Report is 8 commits behind head on master.

Additional details and impacted files
@@                Coverage Diff                @@
##             master     #56864         +/-   ##
=================================================
- Coverage   73.3393%   57.2836%   -16.0558%     
=================================================
  Files          1636       1791        +155     
  Lines        453658     641845     +188187     
=================================================
+ Hits         332710     367672      +34962     
- Misses       100561     249028     +148467     
- Partials      20387      25145       +4758     
Flag Coverage Δ
integration 39.5924% <67.5675%> (?)
unit 72.7377% <75.6756%> (+0.1860%) ⬆️

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

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

Signed-off-by: Rustin170506 <[email protected]>
@ti-chi-bot ti-chi-bot bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 28, 2024
Signed-off-by: Rustin170506 <[email protected]>
Copy link
Member Author

@Rustin170506 Rustin170506 left a comment

Choose a reason for hiding this comment

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

🔢 Self-check (PR reviewed by myself and ready for feedback.)

@Rustin170506
Copy link
Member Author

Rustin170506 commented Oct 28, 2024

Tested locally:

  1. Create the TiDB cluster: tiup playground v8.2.0 --db.binpath /Users/rustin/code/tidb/bin/tidb-server
  2. Check the table:
mysql> use test
Database changed
mysql> select * from mysql.tidb_ddl_notifier;
Empty set (0.00 sec)
  1. Create a new table and check it again:
mysql> create table a(a int);
Query OK, 0 rows affected (0.02 sec)

mysql> select * from mysql.tidb_ddl_notifier;
Empty set (0.00 sec)

mysql> ALTER TABLE a ADD INDEX index_name (a);
Query OK, 0 rows affected (0.10 sec)

mysql> select * from mysql.tidb_ddl_notifier;
Empty set (0.00 sec)

Signed-off-by: Rustin170506 <[email protected]>
@Rustin170506 Rustin170506 requested review from lance6716 and fzzf678 and removed request for lance6716 October 28, 2024 07:25
@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Oct 28, 2024
Copy link

ti-chi-bot bot commented Oct 28, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fzzf678, lance6716

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 28, 2024
Copy link

ti-chi-bot bot commented Oct 28, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-10-28 09:32:13.618562314 +0000 UTC m=+255846.457717853: ☑️ agreed by lance6716.
  • 2024-10-28 10:06:06.000094477 +0000 UTC m=+257878.839250039: ☑️ agreed by fzzf678.

@Rustin170506
Copy link
Member Author

/retest

@ti-chi-bot ti-chi-bot bot merged commit 900cd39 into pingcap:master Oct 28, 2024
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants