Open
Conversation
* DDL statements are implicitly committed by Neo4j and idempotent (IF NOT EXISTS).
ok300
reviewed
Mar 3, 2026
ok300
reviewed
Mar 5, 2026
Contributor
ok300
left a comment
There was a problem hiding this comment.
A single last comment, otherwise LGTM.
Co-authored-by: ok300 <106775972+ok300@users.noreply.github.com>
ok300
approved these changes
Mar 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds slow query logging for Neo4j.
GraphExectrait becomes the main application interface for interacting with the Neo4j database.TracedGraphis a decorator overGraphExecthat logs queries exceeding a configurable time threshold.Graphis a plainGraphExecimplementation that delegates directly toneo4rs::Graph- used when slow query logging is disabled (e.g. migrations, CLI commands).All graph queries now use a custom
Querytype (replacingneo4rs::Query) that carries a label for identification in logs.Note on timing: Measured query time is wall-clock time from the application's perspective. It includes the Neo4j roundtrip, driver-level connection pool acquisition, retry logic, row streaming, and async executor scheduling delays - not just
server-side execution time.
Configuration:
slow_query_threshold_ms- queries exceeding this threshold are logged with their label and timing breakdown (execute vs fetch).log_slow_query_cypher- additionally logs the fully interpolated cypher for slow queries. Has per-query overhead so should not be enabled in production by default.slow_query_logging- set to false to disable tracing entirely (used by migration and mock configs).