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

During Fluent find operations the default renderer is used to render parts of the cypher query, thus ignoring any and all configuration #2927

Closed
THE-ORONCO opened this issue Jul 18, 2024 · 1 comment
Assignees
Labels
type: bug A general bug

Comments

@THE-ORONCO
Copy link

THE-ORONCO commented Jul 18, 2024

When using the org.springframework.data.neo4j.core.FluentFindOperation.FindWithQuery#matching(org.neo4j.cypherdsl.core.Statement, java.util.Map) method (for example when using the Neo4jTemplate) the given statement is rendered using the default renderer. This means any configuration provided via a Configuration-Bean is lost / ignored for this particular statement.
I found this bug because the generated Cypher statements were always rendered with id instead of elementId even though I explicitly defined them via the Cypher-DSL and also set the Neo4J-Version to v5 in the Configuration-Bean.
A possible solution could be to not render the match-statement in place and instead delay the rendering until the configuration is in scope to get the actual renderer.

A minimal example showing the issue is provided here.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Jul 18, 2024
@michael-simons michael-simons self-assigned this Jul 19, 2024
@michael-simons michael-simons added type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged labels Jul 19, 2024
@michael-simons
Copy link
Collaborator

Great catch, @THE-ORONCO A fix is on the way.
Thank you.

michael-simons added a commit that referenced this issue Jul 19, 2024
… in various Cypher-DSL based query extension.

Fixes #2927.

# Conflicts:
#	src/main/java/org/springframework/data/neo4j/core/ReactiveNeo4jTemplate.java
michael-simons added a commit that referenced this issue Jul 19, 2024
… in various Cypher-DSL based query extension.

Fixes #2927.
michael-simons added a commit that referenced this issue Jul 19, 2024
… in various Cypher-DSL based query extension.

Fixes #2927.
michael-simons added a commit that referenced this issue Jul 19, 2024
… in various Cypher-DSL based query extension.

Fixes #2927.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

3 participants