fix: Channel may be released after balance (#37862)
Some checks failed
Code Checker / Code Checker AMD64 Ubuntu 22.04 (push) Has been cancelled
Code Checker / Code Checker Amazonlinux 2023 (push) Has been cancelled
Code Checker / Code Checker rockylinux8 (push) Has been cancelled
Mac Code Checker / Code Checker MacOS 13 (push) Has been cancelled
Build and test / Build and test AMD64 Ubuntu 22.04 (push) Has been cancelled
Update Knowhere Commit / update-knowhere-commit (push) Has been cancelled
Build and test / UT for Cpp (push) Has been cancelled
Build and test / UT for Go (push) Has been cancelled
Build and test / Integration Test (push) Has been cancelled
Build and test / Upload Code Coverage (push) Has been cancelled

issue: #37830
casue dist handler doesn't set channel's version, so if channel checker
try to dedup channel, it may release the new delegator after balance
finished.

this PR fix the way to set proper version for channel.

Signed-off-by: Wei Liu <wei.liu@zilliz.com>
This commit is contained in:
wei liu 2024-11-21 10:40:31 +08:00 committed by GitHub
parent f3a36f8a29
commit b983ef9fca
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -181,7 +181,11 @@ func (dh *distHandler) updateChannelsDistribution(resp *querypb.GetDataDistribut
Version: ch.GetVersion(),
}
} else {
channel = channelInfo.Clone()
channel = &meta.DmChannel{
VchannelInfo: channelInfo.VchannelInfo,
Node: resp.GetNodeID(),
Version: ch.GetVersion(),
}
}
updates = append(updates, channel)
}