Fix knowledge compiler Go port regressions (MySQL 1101 + Start deadlock) (#17599)

Two regressions from #17536: (1) MySQL 8.0 AutoMigrate crash on
knowledge_compile_docs (Error 1101) from a TEXT default; (2) ingestor
Start() sync.Once re-entrant deadlock. Both fixed with regression tests.
This commit is contained in:
Zhichang Yu
2026-07-31 11:25:26 +08:00
committed by GitHub
parent cd964dd700
commit 650387b2fd
4 changed files with 68 additions and 9 deletions

View File

@@ -88,6 +88,13 @@ func GetMessageQueueEngine() MessageQueue {
return messageQueueEngine
}
// SetMessageQueueEngine installs the global message-queue engine. It exists
// primarily as a test seam so callers can drive Start() without a real server
// config; production code uses InitMessageQueueEngine.
func SetMessageQueueEngine(mq MessageQueue) {
messageQueueEngine = mq
}
func InitMessageQueueEngine(messageQueueType string) error {
config := server.GetConfig()
switch messageQueueType {