-
Notifications
You must be signed in to change notification settings - Fork 412
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
[flash-423] fix ch fail to start when tidb cluster is not ready. #203
Conversation
/run-integration-tests |
2 similar comments
/run-integration-tests |
/run-integration-tests |
/run-integration-tests |
1 similar comment
/run-integration-tests |
dbms/src/Server/Server.cpp
Outdated
@@ -411,7 +411,19 @@ int Server::main(const std::vector<std::string> & /*args*/) | |||
global_context->setCurrentDatabase(default_database); | |||
|
|||
/// Then, sync schemas with TiDB, and initialize schema sync service. | |||
global_context->getTMTContext().getSchemaSyncer()->syncSchemas(*global_context); | |||
for (;;) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a retry times?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
dbms/src/Server/Server.cpp
Outdated
catch (Poco::Exception & e) | ||
{ | ||
LOG_ERROR(log, "Bootstrap failed because sync schema error: " << e.displayText() << "\n We will sleep 3 seconds and try again."); | ||
::sleep(3); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sleep(1) is good, will not occupy much CPU
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
/run-integration-tests |
@innerr PTAL again |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Signed-off-by: Wish <breezewish@outlook.com> Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com> Co-authored-by: Wish <breezewish@outlook.com> Co-authored-by: JaySon-Huang <tshent@qq.com>
Signed-off-by: Wish <breezewish@outlook.com> Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com> Co-authored-by: Wish <breezewish@outlook.com> Co-authored-by: JaySon-Huang <tshent@qq.com>
Signed-off-by: Wish <breezewish@outlook.com> Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com> Co-authored-by: Wish <breezewish@outlook.com> Co-authored-by: JaySon-Huang <tshent@qq.com>
Signed-off-by: Wish <breezewish@outlook.com> Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com> Co-authored-by: Wish <breezewish@outlook.com> Co-authored-by: JaySon-Huang <tshent@qq.com>
Signed-off-by: Wish <breezewish@outlook.com> Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com> Co-authored-by: Wish <breezewish@outlook.com> Co-authored-by: JaySon-Huang <tshent@qq.com>
Signed-off-by: Wish <breezewish@outlook.com> Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com> Co-authored-by: Wish <breezewish@outlook.com> Co-authored-by: JaySon-Huang <tshent@qq.com>
retry in an endless loop. By the way, I have tested manually :D