Skip to content

Making the get_graph method public#2609

Open
rodrigolece wants to merge 1 commit into
db_v4from
fix/private-method
Open

Making the get_graph method public#2609
rodrigolece wants to merge 1 commit into
db_v4from
fix/private-method

Conversation

@rodrigolece
Copy link
Copy Markdown

What changes were proposed in this pull request?

Just making the get_graph method public

Why are the changes needed?

Because compilation errors.

Does this PR introduce any user-facing change? If yes is this documented?

No

How was this patch tested?

It hasn't been tested.

Are there any further changes required?

Not that I can think of.

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented May 14, 2026

CLA assistant check
All committers have signed the CLA.

@rodrigolece
Copy link
Copy Markdown
Author

For context, these are the errors:

image

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'Rust Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 2.

Benchmark suite Current: 74b778b Previous: 9823ef7 Ratio
lotr_graph/num_edges 4 ns/iter (± 0) 0 ns/iter (± 0) +∞
lotr_graph/num_nodes 4 ns/iter (± 0) 1 ns/iter (± 0) 4
lotr_graph/has_node_nonexisting 5 ns/iter (± 0) 2 ns/iter (± 0) 2.50
lotr_graph/iterate_exploded_edges 645165 ns/iter (± 8213) 285473 ns/iter (± 2920) 2.26
lotr_graph/graph_latest 3 ns/iter (± 0) 0 ns/iter (± 0) +∞
lotr_graph_materialise/materialize 7978478 ns/iter (± 31549) 1564816 ns/iter (± 35303) 5.10
lotr_graph_window_100/num_nodes 14 ns/iter (± 0) 5 ns/iter (± 0) 2.80
lotr_graph_window_100/iterate_exploded_edges 863287 ns/iter (± 2051) 325242 ns/iter (± 847) 2.65
lotr_graph_window_100_materialise/materialize 8600930 ns/iter (± 58300) 1669150 ns/iter (± 10700) 5.15
lotr_graph_window_10/has_node_existing 154 ns/iter (± 13) 62 ns/iter (± 11) 2.48
lotr_graph_window_10/iterate nodes 35439 ns/iter (± 168) 11339 ns/iter (± 40) 3.13
lotr_graph_window_10/iterate edges 103380 ns/iter (± 230) 48684 ns/iter (± 211) 2.12
lotr_graph_window_10/iterate_exploded_edges 432400 ns/iter (± 947) 155788 ns/iter (± 1001) 2.78
lotr_graph_window_10_materialise/materialize 3718836 ns/iter (± 42151) 971980 ns/iter (± 4278) 3.83
lotr_graph_subgraph_10pc/has_node_nonexisting 5 ns/iter (± 0) 2 ns/iter (± 0) 2.50
lotr_graph_subgraph_10pc_materialise/materialize 1679875 ns/iter (± 19526) 334634 ns/iter (± 1287) 5.02
lotr_graph_subgraph_10pc_windowed/has_node_existing 163 ns/iter (± 15) 62 ns/iter (± 14) 2.63
lotr_graph_subgraph_10pc_windowed/iterate nodes 5501 ns/iter (± 111) 1365 ns/iter (± 3) 4.03
lotr_graph_subgraph_10pc_windowed_materialise/materialize 1028437 ns/iter (± 19826) 230399 ns/iter (± 2617) 4.46
lotr_graph_window_50_layered/num_edges 78680 ns/iter (± 1595) 38714 ns/iter (± 1017) 2.03
lotr_graph_window_50_layered/num_edges_temporal 164914 ns/iter (± 1900) 70121 ns/iter (± 7586) 2.35
lotr_graph_window_50_layered/has_node_existing 454 ns/iter (± 23) 129 ns/iter (± 12) 3.52
lotr_graph_window_50_layered/has_node_nonexisting 5 ns/iter (± 0) 2 ns/iter (± 0) 2.50
lotr_graph_window_50_layered/iterate nodes 81063 ns/iter (± 861) 19308 ns/iter (± 47) 4.20
lotr_graph_window_50_layered/iterate edges 206735 ns/iter (± 421) 83616 ns/iter (± 1318) 2.47
lotr_graph_window_50_layered/graph_latest 82794 ns/iter (± 566) 36649 ns/iter (± 916) 2.26
lotr_graph_window_50_layered_materialise/materialize 34243265 ns/iter (± 117886) 3488825 ns/iter (± 24948) 9.82
lotr_graph_persistent_window_50_layered/num_edges_temporal 676358 ns/iter (± 5460) 192686 ns/iter (± 1569) 3.51
lotr_graph_persistent_window_50_layered/has_node_existing 500 ns/iter (± 371) 174 ns/iter (± 83) 2.87
lotr_graph_persistent_window_50_layered/has_node_nonexisting 5 ns/iter (± 0) 2 ns/iter (± 0) 2.50
lotr_graph_persistent_window_50_layered/iterate nodes 107806 ns/iter (± 234) 35886 ns/iter (± 191) 3.00
lotr_graph_persistent_window_50_layered/iterate edges 190069 ns/iter (± 1075) 84161 ns/iter (± 596) 2.26
lotr_graph_persistent_window_50_layered/iterate_exploded_edges 4923492 ns/iter (± 70464) 1659940 ns/iter (± 19402) 2.97
lotr_graph_persistent_window_50_layered/graph_latest 119627 ns/iter (± 1897) 57549 ns/iter (± 4809) 2.08
lotr_graph_persistent_window_50_layered_materialise/materialize 61028854 ns/iter (± 101471) 5298035 ns/iter (± 147912) 11.52
lotr_graph/proto_encode 9773662 ns/iter (± 191013) 1157897 ns/iter (± 73709) 8.44

This comment was automatically generated by workflow using github-action-benchmark.

/// # ⚠ Bypasses all permission checks — do not call from resolvers directly.
/// Use `get_graph_with_read_permission`, `get_raw_graph_with_read_permission`, or
/// `get_graph_with_write_permission` instead.
async fn get_graph(&self, path: &str) -> Result<GraphWithVectors, Arc<GQLError>> {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This method should not be public as it bypasses all permissions checks, you should be using get_graph_with_read_permissions or get_graph_with_write_permission (depending on whether the graph will be modified) instead as per the comment above.

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.

3 participants