Skip to content

Commit 639566c

Browse files
authored
Merge pull request #725 from mronstro/22.10-dev
RONDB-920: Ensure that we can handle get SDIs from 22.10 and 24.10 ve…
2 parents 31a7dc3 + 48cb9d4 commit 639566c

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

storage/ndb/plugin/ndb_dd_sdi.cc

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,15 @@ static bool check_sdi_compatibility(const dd::RJ_Document &doc) {
101101
assert(doc.HasMember("mysqld_version_id"));
102102
const dd::RJ_Value &mysqld_version_id = doc["mysqld_version_id"];
103103
assert(mysqld_version_id.IsUint64());
104-
if (mysqld_version_id.GetUint64() > std::uint64_t(MYSQL_VERSION_ID)) {
105-
// Cannot deserialize SDIs from newer versions
104+
if (mysqld_version_id.GetUint64() > std::uint64_t(221100)) {
105+
/**
106+
* We cannot handle deserialize from version newer than 22.10,
107+
* thus we cannot handle tables created in e.g. 24.10.x.
108+
* We can handle tables created in earlier versions always.
109+
*
110+
* Since this code is only used in 22.10.13 and newer we need
111+
* not check any more.
112+
*/
106113
my_error(ER_IMP_INCOMPATIBLE_MYSQLD_VERSION, MYF(0),
107114
mysqld_version_id.GetUint64(), std::uint64_t(MYSQL_VERSION_ID));
108115
return true;

0 commit comments

Comments
 (0)