-
Notifications
You must be signed in to change notification settings - Fork 998
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
fix(server): Fix replication bug, add gdb opt to pytest #513
Conversation
args = [self.params.path, *arglist] | ||
if self.params.gdb: | ||
args = ["gdb", "--ex", "r", "--args"] + args |
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.
I'm not sure this option is worth it.
Its helpful for me, because in case of a bad signal, the whole process stops. Once brought back to foreground, gdb is directly active and can be used to get stacktrace/dump variables/stack.
However, it doesn't allow customizing anything before start. Like selecting only a few instances, or setting breakpoints. The latter can be fixed by making the gdb parameter a string and forwarding it to gdb, so just --gdb
becomes --gdb="break dflycmd.cc:100; break replica.cc:100"
af5fda8
to
6c31c69
Compare
Signed-off-by: Vladislav Oleshko <[email protected]>
6c31c69
to
9df4ee7
Compare
|
||
// Start rdb saving. | ||
SaveMode mode = shard == nullptr ? SaveMode::SUMMARY : SaveMode::SINGLE_SHARD; | ||
std::error_code local_ec = snapshot->Start(mode, abs_path.generic_string(), scripts); | ||
error_code local_ec = snapshot->Start(mode, full_path.generic_string(), scripts); |
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.
was it a bug, @dranikpg ?
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.
This is refactoring included. I broke it in the last PR unknowingly
LGTM. For the protocol, can you tell what the bugs were? |
|
The third change was increasing some general wait points in pytests, because the CI env is really slow. However, this has also the benefit of catching multi-threading bugs that are hard to reproduce on fast machines |
Fixes bug in replica.cc
Add option to run instances inside gdb