Skip to content
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

Cherry pick 3.5.0 (0428) #5532

Merged
merged 1 commit into from
Apr 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/graph/executor/algo/AllPathsExecutor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,9 @@ folly::Future<Status> AllPathsExecutor::buildPathMultiJobs() {

if (!paths.empty()) {
time::Duration convertPathTime;
if (paths.size() > limit_) {
paths.resize(limit_);
}
for (auto& path : paths) {
result_.rows.emplace_back(convertNPath2Row(path.first, path.second));
}
Expand Down
8 changes: 8 additions & 0 deletions tests/tck/features/path/AllPath.feature
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,14 @@ Feature: All Path
| <("Tony Parker")-[:like]->("LaMarcus Aldridge")-[:like]->("Tim Duncan")> |
| <("Tony Parker")-[:like]->("LaMarcus Aldridge")-[:like]->("Tony Parker")-[:like]->("Tim Duncan")> |
| <("Tony Parker")-[:like]->("Manu Ginobili")-[:like]->("Tim Duncan")> |
When executing query:
"""
FIND ALL PATH FROM "Tim Duncan" TO "Tony Parker","Spurs" OVER like,serve UPTO 10 STEPS YIELD path as p
| LIMIT 3 | YIELD count(*) AS cnt
"""
Then the result should be, in any order, with relax comparison:
| cnt |
| 3 |

Scenario: [1] ALL PATH REVERSELY
When executing query:
Expand Down