-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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_shortest_path_crash #4352
fix_shortest_path_crash #4352
Conversation
@@ -86,6 +80,7 @@ class ShortestPathBase { | |||
std::unordered_map<std::string, std::string>* stats_{nullptr}; | |||
size_t maxStep_; | |||
bool singleShortest_{true}; | |||
folly::SpinLock statsLock_; |
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.
How about other members?
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.
other members will not be written by multiple threads at the same time
@@ -264,6 +264,9 @@ folly::Future<bool> SingleShortestPath::buildEvenPath(size_t rowNum, | |||
return false; | |||
} | |||
for (auto& meetVertex : vertices) { | |||
if (!meetVertex.isVertex()) { |
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.
Why this isn't vertex?
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.
vertices may contain EMPTY values in exceptional cases
* force cache the docker layer (#4331) * check god role exist when meta init (#4330) * check god role exist when meta init * return error if kv fail Co-authored-by: Doodle <[email protected]> * Fix object pool mtsafe. (#4332) * Fix object pool mtsafe. * Fix lock. * Fixed web service crash (#4334) Co-authored-by: Sophie <[email protected]> * Fix get edges transform rule. (#4328) 1. Input/Ouput variables. 2. Keep column names of Limit same with input plan node. Co-authored-by: Sophie <[email protected]> * fix rc docker (#4336) * add lock (#4352) * fix map concurrency issue (#4344) * fix mutex in map * add test * move the order Co-authored-by: Sophie <[email protected]> * add stats under index conditions (#4353) Co-authored-by: Harris.Chu <[email protected]> Co-authored-by: jimingquan <[email protected]> Co-authored-by: Doodle <[email protected]> Co-authored-by: shylock <[email protected]> Co-authored-by: dutor <[email protected]> Co-authored-by: panda-sheep <[email protected]>
What type of PR is this?
What problem(s) does this PR solve?
Issue(s) number:
Description:
Graph crash when running tck manually
Can't be reproduced consistently.
Tck is run with 16 concurrent threads.
How do you solve it?
shared variables are locked before use in multi-threading environment
Special notes for your reviewer, ex. impact of this fix, design document, etc:
Checklist:
Tests:
Affects:
Release notes:
Please confirm whether to be reflected in release notes and how to describe: