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

refact: remove early cycle detection & limit max depth #1723

Merged
merged 4 commits into from
Jan 12, 2022
Merged

Conversation

imbajin
Copy link
Member

@imbajin imbajin commented Jan 4, 2022

  1. limit max depth to avoid stackoverflow
  2. remove useless cycle detection due to it will remove valid path

TODO: maybe we should refactor the recursive findPath to for-loop

limit max depth to avoid stackoverflow
@codecov
Copy link

codecov bot commented Jan 4, 2022

Codecov Report

Merging #1723 (9b7b503) into master (132582a) will increase coverage by 0.36%.
The diff coverage is 25.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1723      +/-   ##
============================================
+ Coverage     66.55%   66.92%   +0.36%     
- Complexity     7085     7110      +25     
============================================
  Files           423      423              
  Lines         35598    35615      +17     
  Branches       4959     4963       +4     
============================================
+ Hits          23692    23835     +143     
+ Misses         9505     9374     -131     
- Partials       2401     2406       +5     
Impacted Files Coverage Δ
...aidu/hugegraph/api/traversers/NeighborRankAPI.java 81.08% <0.00%> (+0.52%) ⬆️
...aidu/hugegraph/api/traversers/PersonalRankAPI.java 70.73% <0.00%> (ø)
...a/com/baidu/hugegraph/api/traversers/PathsAPI.java 71.42% <50.00%> (ø)
...om/baidu/hugegraph/api/filter/ExceptionFilter.java 56.73% <0.00%> (-3.48%) ⬇️
...idu/hugegraph/job/schema/RebuildIndexCallable.java
...raph/job/schema/OlapPropertyKeyCreateCallable.java
...ugegraph/job/schema/VertexLabelRemoveCallable.java
...hugegraph/job/schema/IndexLabelRemoveCallable.java
...com/baidu/hugegraph/job/schema/SchemaCallable.java
...raph/job/schema/OlapPropertyKeyRemoveCallable.java
... and 23 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 132582a...9b7b503. Read the comment docs.

coderzc
coderzc previously approved these changes Jan 4, 2022
@javeme javeme merged commit e9cef74 into master Jan 12, 2022
@javeme javeme deleted the fix-paths branch January 12, 2022 12:09
javeme pushed a commit that referenced this pull request Jan 12, 2022
* remove useless ring detection due to it will remove valid path
* limit max depth to 5000 to avoid stackoverflow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants