Skip to content

Commit fc06122

Browse files
Merge remote-tracking branch 'origin/main' into avoid-flaky-topo-concurrency-test
2 parents 37eb29a + b1f6147 commit fc06122

File tree

277 files changed

+7834
-5348
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

277 files changed

+7834
-5348
lines changed

.github/workflows/cluster_endtoend_onlineddl_vrepl.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,10 @@ jobs:
149149
binlog-transaction-compression=ON
150150
EOF
151151
152+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
153+
binlog-row-value-options=PARTIAL_JSON
154+
EOF
155+
152156
# run the tests however you normally do, then produce a JUnit XML file
153157
eatmydata -- go run test.go -docker=false -follow -shard onlineddl_vrepl | tee -a output.txt | go-junit-report -set-exit-code > report.xml
154158

.github/workflows/cluster_endtoend_onlineddl_vrepl_stress.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,10 @@ jobs:
149149
binlog-transaction-compression=ON
150150
EOF
151151
152+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
153+
binlog-row-value-options=PARTIAL_JSON
154+
EOF
155+
152156
# run the tests however you normally do, then produce a JUnit XML file
153157
eatmydata -- go run test.go -docker=false -follow -shard onlineddl_vrepl_stress | tee -a output.txt | go-junit-report -set-exit-code > report.xml
154158

.github/workflows/cluster_endtoend_onlineddl_vrepl_stress_suite.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,10 @@ jobs:
149149
binlog-transaction-compression=ON
150150
EOF
151151
152+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
153+
binlog-row-value-options=PARTIAL_JSON
154+
EOF
155+
152156
# run the tests however you normally do, then produce a JUnit XML file
153157
eatmydata -- go run test.go -docker=false -follow -shard onlineddl_vrepl_stress_suite | tee -a output.txt | go-junit-report -set-exit-code > report.xml
154158

.github/workflows/cluster_endtoend_onlineddl_vrepl_suite.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,10 @@ jobs:
149149
binlog-transaction-compression=ON
150150
EOF
151151
152+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
153+
binlog-row-value-options=PARTIAL_JSON
154+
EOF
155+
152156
# run the tests however you normally do, then produce a JUnit XML file
153157
eatmydata -- go run test.go -docker=false -follow -shard onlineddl_vrepl_suite | tee -a output.txt | go-junit-report -set-exit-code > report.xml
154158

.github/workflows/cluster_endtoend_schemadiff_vrepl.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,10 @@ jobs:
149149
binlog-transaction-compression=ON
150150
EOF
151151
152+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
153+
binlog-row-value-options=PARTIAL_JSON
154+
EOF
155+
152156
# run the tests however you normally do, then produce a JUnit XML file
153157
eatmydata -- go run test.go -docker=false -follow -shard schemadiff_vrepl | tee -a output.txt | go-junit-report -set-exit-code > report.xml
154158

.github/workflows/cluster_endtoend_vreplication_across_db_versions.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_across_db_versions | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_basic.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_basic | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_cellalias.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_cellalias | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_copy_parallel.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_copy_parallel | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_foreign_key_stress.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_foreign_key_stress | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_mariadb_to_mysql.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_mariadb_to_mysql | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_migrate.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_migrate | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_multi_tenant.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_multi_tenant | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_partial_movetables_and_materialize.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_partial_movetables_and_materialize | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_v2.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_v2 | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/cluster_endtoend_vreplication_vtctldclient_vdiff2_movetables_tz.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ jobs:
166166
binlog-transaction-compression=ON
167167
EOF
168168
169+
cat <<-EOF>>./config/mycnf/mysql8026.cnf
170+
binlog-row-value-options=PARTIAL_JSON
171+
EOF
172+
169173
# run the tests however you normally do, then produce a JUnit XML file
170174
eatmydata -- go run test.go -docker=false -follow -shard vreplication_vtctldclient_vdiff2_movetables_tz | tee -a output.txt | go-junit-report -set-exit-code > report.xml
171175

.github/workflows/codecov.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ jobs:
111111
112112
- name: Upload coverage reports to codecov.io
113113
if: steps.changes.outputs.changed_files == 'true'
114-
uses: codecov/codecov-action@v4
114+
uses: codecov/codecov-action@015f24e6818733317a2da2edd6290ab26238649a # https://github.com/codecov/codecov-action/releases/tag/v5.0.7
115115
with:
116116
fail_ci_if_error: true
117117
verbose: true

.github/workflows/unit_test_evalengine_mysql57.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,9 @@ jobs:
163163
164164
export NOVTADMINBUILD=1
165165
export VTEVALENGINETEST="1"
166+
# We sometimes need to alter the behavior based on the platform we're
167+
# testing, e.g. MySQL 5.7 vs 8.0.
168+
export CI_DB_PLATFORM="mysql57"
166169
167170
eatmydata -- make unit_test | tee -a output.txt | go-junit-report -set-exit-code > report.xml
168171

.github/workflows/unit_test_evalengine_mysql80.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,9 @@ jobs:
153153
154154
export NOVTADMINBUILD=1
155155
export VTEVALENGINETEST="1"
156+
# We sometimes need to alter the behavior based on the platform we're
157+
# testing, e.g. MySQL 5.7 vs 8.0.
158+
export CI_DB_PLATFORM="mysql80"
156159
157160
eatmydata -- make unit_test | tee -a output.txt | go-junit-report -set-exit-code > report.xml
158161

.github/workflows/unit_test_evalengine_mysql84.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,9 @@ jobs:
153153
154154
export NOVTADMINBUILD=1
155155
export VTEVALENGINETEST="1"
156+
# We sometimes need to alter the behavior based on the platform we're
157+
# testing, e.g. MySQL 5.7 vs 8.0.
158+
export CI_DB_PLATFORM="mysql84"
156159
157160
eatmydata -- make unit_test | tee -a output.txt | go-junit-report -set-exit-code > report.xml
158161

.github/workflows/unit_test_mysql57.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,9 @@ jobs:
163163
164164
export NOVTADMINBUILD=1
165165
export VTEVALENGINETEST="0"
166+
# We sometimes need to alter the behavior based on the platform we're
167+
# testing, e.g. MySQL 5.7 vs 8.0.
168+
export CI_DB_PLATFORM="mysql57"
166169
167170
eatmydata -- make unit_test | tee -a output.txt | go-junit-report -set-exit-code > report.xml
168171

.github/workflows/unit_test_mysql80.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,9 @@ jobs:
153153
154154
export NOVTADMINBUILD=1
155155
export VTEVALENGINETEST="0"
156+
# We sometimes need to alter the behavior based on the platform we're
157+
# testing, e.g. MySQL 5.7 vs 8.0.
158+
export CI_DB_PLATFORM="mysql80"
156159
157160
eatmydata -- make unit_test | tee -a output.txt | go-junit-report -set-exit-code > report.xml
158161

.github/workflows/unit_test_mysql84.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,9 @@ jobs:
153153
154154
export NOVTADMINBUILD=1
155155
export VTEVALENGINETEST="0"
156+
# We sometimes need to alter the behavior based on the platform we're
157+
# testing, e.g. MySQL 5.7 vs 8.0.
158+
export CI_DB_PLATFORM="mysql84"
156159
157160
eatmydata -- make unit_test | tee -a output.txt | go-junit-report -set-exit-code > report.xml
158161

changelog/22.0/22.0.0/summary.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- **[RPC Changes](#rpc-changes)**
99
- **[Prefer not promoting a replica that is currently taking a backup](#reparents-prefer-not-backing-up)**
1010
- **[VTOrc Config File Changes](#vtorc-config-file-changes)**
11+
- **[Support for More Efficient JSON Replication](#efficient-json-replication)**
1112
- **[Minor Changes](#minor-changes)**
1213
- **[VTTablet Flags](#flags-vttablet)**
1314
- **[Topology read concurrency behaviour changes](#topo-read-concurrency-changes)**
@@ -59,6 +60,12 @@ The following fields can be dynamically changed -
5960

6061
To upgrade to the newer version of the configuration file, first switch to using the flags in your current deployment before upgrading. Then you can switch to using the configuration file in the newer release.
6162

63+
### <a id="efficient-json-replication"/>Support for More Efficient JSON Replication</a>
64+
65+
In [#7345](https://github.com/vitessio/vitess/pull/17345) we added support for [`--binlog-row-value-options=PARTIAL_JSON`](https://dev.mysql.com/doc/refman/en/replication-options-binary-log.html#sysvar_binlog_row_value_options). You can read more about [this feature added to MySQL 8.0 here](https://dev.mysql.com/blog-archive/efficient-json-replication-in-mysql-8-0/).
66+
67+
If you are using MySQL 8.0 or later and using JSON columns, you can now enable this MySQL feature across your Vitess cluster(s) to lower the disk space needed for binary logs and improve the CPU and memory usage in both `mysqld` (standard intrashard MySQL replication) and `vttablet` ([VReplication](https://vitess.io/docs/reference/vreplication/vreplication/)) without losing any capabilities or features.
68+
6269

6370
## <a id="minor-changes"/>Minor Changes</a>
6471

examples/backups/create_commerce_schema.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
create table if not exists product(
2-
sku varbinary(128),
3-
description varbinary(128),
2+
sku varchar(128),
3+
description varchar(128),
44
price bigint,
55
primary key(sku)
66
) ENGINE=InnoDB;
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
create table if not exists customer(
22
customer_id bigint not null,
3-
email varbinary(128),
3+
email varchar(128),
44
primary key(customer_id)
55
) ENGINE=InnoDB;
66

77
create table if not exists corder(
88
order_id bigint not null,
99
customer_id bigint,
10-
sku varbinary(128),
10+
sku varchar(128),
1111
price bigint,
1212
primary key(order_id)
1313
) ENGINE=InnoDB;

examples/compose/default_vschema.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"sharded": false,
33
"vindexes": {
4-
"hash": {
5-
"type": "hash"
4+
"xxhash": {
5+
"type": "xxhash"
66
}
77
}
8-
}
8+
}

examples/compose/lookup_keyspace_vschema.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,22 @@
55
"column_vindexes": [
66
{
77
"column": "id",
8-
"name": "hash"
8+
"name": "xxhash"
99
}
1010
]
1111
},
1212
"tokens_token_lookup": {
1313
"column_vindexes": [
1414
{
1515
"column": "id",
16-
"name": "hash"
16+
"name": "xxhash"
1717
}
1818
]
1919
}
2020
},
2121
"vindexes": {
22-
"hash": {
23-
"type": "hash"
22+
"xxhash": {
23+
"type": "xxhash"
2424
}
2525
}
2626
}

examples/compose/test_keyspace_vschema.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"column_vindexes": [
66
{
77
"column": "page",
8-
"name": "hash"
8+
"name": "xxhash"
99
},
1010
{
1111
"column": "message",
@@ -17,7 +17,7 @@
1717
"column_vindexes": [
1818
{
1919
"column": "page",
20-
"name": "hash"
20+
"name": "xxhash"
2121
},
2222
{
2323
"column": "token",
@@ -27,8 +27,8 @@
2727
}
2828
},
2929
"vindexes": {
30-
"hash": {
31-
"type": "hash"
30+
"xxhash": {
31+
"type": "xxhash"
3232
},
3333
"messages_message_lookup": {
3434
"type": "lookup_hash",
Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
{
22
"sharded": true,
33
"vindexes": {
4-
"hash": {
5-
"type": "hash"
4+
"xxhash": {
5+
"type": "xxhash"
66
}
77
},
8-
"tables": {
9-
}
10-
}
8+
"tables": {}
9+
}

0 commit comments

Comments
 (0)