Skip to content

feat(interactive): Implement a c++ wrapper for compiler's GraphPlanner#4310

Merged
longbinlai merged 33 commits intoalibaba:mainfrom
zhanglei1949:call-compiler-via-jni
Jan 14, 2025
Merged

feat(interactive): Implement a c++ wrapper for compiler's GraphPlanner#4310
longbinlai merged 33 commits intoalibaba:mainfrom
zhanglei1949:call-compiler-via-jni

Conversation

@zhanglei1949
Copy link
Collaborator

@zhanglei1949 zhanglei1949 commented Nov 4, 2024

  • Implement a JNI-based c++ Wrapper for compiler's GraphPlanner, which is used to generate physical plan from a cypher query string.
  • Some minor fix for compiler's code.

Fix #4306

Usage:

gs::jni::GraphPlannerWrapper planner(java_path, java_library_path, graph_schema_path);
if (!planner.is_valid()) {
  LOG(ERROR) << "Invalid GraphPlannerWrapper.";
  return 1;
}
auto plan = planner.CompilePlan(compiler_config_path, cypher_query)

The CompilePlan are exposed by two ways: JNI or REST API, see https://github.com/zhanglei1949/GraphScope/blob/call-compiler-via-jni/docs/interactive_engine/graph_planner.md for more usages.

Committed-by: xiaolei.zl from Dev container
Committed-by: xiaolei.zl from Dev container
@codecov-commenter
Copy link

codecov-commenter commented Nov 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 58.78%. Comparing base (05254bd) to head (837a07e).
Report is 1 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##             main    #4310       +/-   ##
===========================================
+ Coverage   34.33%   58.78%   +24.44%     
===========================================
  Files         126       12      -114     
  Lines       13257      592    -12665     
===========================================
- Hits         4552      348     -4204     
+ Misses       8705      244     -8461     

see 126 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

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

Committed-by: xiaolei.zl from Dev container
@github-actions
Copy link
Contributor

github-actions bot commented Nov 4, 2024

Please check the preview of the documentation changes at
https://c8e561d0.graphscope-docs-preview.pages.dev

@zhanglei1949 zhanglei1949 changed the title feat(interactive): Implement a java wrapper for compiler's GraphPlanner feat(interactive): Implement a c++ wrapper for compiler's GraphPlanner Nov 4, 2024
Committed-by: xiaolei.zl from Dev container
@zhanglei1949 zhanglei1949 requested a review from liulx20 November 5, 2024 02:05
shirly121
shirly121 previously approved these changes Nov 5, 2024
Committed-by: xiaolei.zl from Dev container
@liulx20 liulx20 force-pushed the call-compiler-via-jni branch from 44ebffd to e217d75 Compare December 12, 2024 11:01
@longbinlai longbinlai merged commit 19d728e into alibaba:main Jan 14, 2025
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.

feat(interactive): Support calling compiler via JNI

5 participants