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

Is it possible to add a new example to the data module to use Spring Data Neo4j? #374

Open
yacosta738 opened this issue Feb 9, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@yacosta738
Copy link

yacosta738 commented Feb 9, 2023

The Spring Data Neo4j module already has a reactive repository, ReactiveNeo4jRepository, but it presents a problem: there is no support for Criteria. A similar concept is used with Example<T> and ExampleMatcher, but it was complicated to add this module in place of MongoDB.

I would be very grateful if you could give me some advice or example.

Thank you @siyual-park

https://neo4j.com/docs/getting-started/current/languages-guides/java/spring-data-neo4j/

@yacosta738 yacosta738 added the enhancement New feature or request label Feb 9, 2023
@siyul-park
Copy link
Owner

siyul-park commented Mar 29, 2023

I have redefined my own Criterion and Repository interface to include all difference. I looked inside implementations such as ReactiveRepository, found a direct query request method used by ReactiveRepository, and used a method of directly implementing Repository interface by converting Criteria into a specific query.

I don't use Neo4j, so I don't have any examples of implementation, but I think I'll add a new repository implementation like the r2dbc, mongo, in_memory implementation that exists on https://github.com/siyual-park/spring-webflux-multi-module-boilerplate/tree/master/module/data/src/main/kotlin/io/github/siyual_park/data/repository .

@yacosta738
Copy link
Author

😌 Hello! I was trying to make my own implementation to use Neo4j, taking your code as a base, but I'm having some problems with some tests. I suspect they have to do with concurrency issues. Apparently, some tests fail to find the element in the Neo4j database when concurrent calls are chained to modify an element in the database. I don't know if you have time to look at my code since I don't know the reason why those two tests are failing.

@siyul-park the example tests is in this class and my PR is yacosta738/astrum#21

Also, I opened an issue to the SDN guys to see if they can help me. The issue that describes the problem is: spring-projects/spring-data-neo4j#2717

Any help or clue you can give me will be greatly appreciated. Thank you in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants