Questions tagged [spring-data-neo4j-4]

The Spring Data Neo4j project, as part of the Spring Data initiative, aims to simplify development with the Neo4j graph database. Like JPA, it uses annotations on simple POJO domain objects. Together with metadata, the annotations drive mapping the POJO entities and their fields to nodes, relationships, and properties in the graph database.

For version 4, Spring Data Neo4j has been rewritten from scratch to natively support Neo4j deployments in standalone server mode. It uses Cypher, the Neo4j query language, and the HTTP protocol to communicate with the database.

The guide for Spring Data Neo4j 4 is available at http://docs.spring.io/spring-data/neo4j/docs/4.0.0.M1/reference/html/

517 questions
0
votes
1 answer

Multiple/Optional EndNode Neo4j

Current scenario: User is able to have a Car and a Motorcycle, so a user could have 1 relation [:OWNS] :Car and another to :Motorcycle. It is also possible for the user to have neither or just one of them. U->C & U->M U->C U Current relationship…
kenlz
  • 461
  • 7
  • 22
0
votes
2 answers

Neo4j OGM Neo4jSession variable substitution queries fail

For me: neo4jSession.query("MATCH (n:Widget) WHERE (n.partNumber STARTS WITH '001') RETURN n.partNumber AS id, n.name AS description, n.urn AS urn LIMIT 10", Collections.emptyMap()); works. This query does not work: String query = "MATCH…
Eric Fulton
  • 133
  • 1
  • 9
0
votes
1 answer

Using Cypher to autogenerate IDs for SDN4

I have created a neo4j model with text file of cypher statements. Now i'd like to create an application that uses this database, and I'll be using SDN4. In my @NodeEntity class, I will need to have the GraphID of type Longdeclared. But this ID gets…
aaaaarrrgghhh
  • 397
  • 5
  • 16
0
votes
1 answer

Java8 and Spring Data Neo4j application queries

I have a bunch of questions regarding Java 8 and SDN4. I created a model in Neo4j v3.0, played a bit with Cypher queries, and now moved to creating a Spring Boot application. As i started coding classes in Java, I've begun to rethink some of my…
0
votes
1 answer

Spring SDN 4.1 and @Async on @Transactional method

I have a method a in a class A that calls a method b in a class B @Service public class A { private B classB; ... @Async @Transactional public void a() { classB.b(); } } @Service public class B { ... …
aGO
  • 1,263
  • 14
  • 30
0
votes
1 answer

GraphRepository and autogenerating code for method findByName(String) don't works

When I uncomment this line in this interface I get error while Spring run. @Repository public interface PersonRepository extends GraphRepository { //Person findByName(String name); } Output from run: 2016-06-08 23:27:58.580 INFO 6723…
Marcin
  • 422
  • 6
  • 17
0
votes
1 answer

Neo4j NullPointerException while running query

this is my configuration: @Bean public org.neo4j.ogm.config.Configuration getConfiguration() { org.neo4j.ogm.config.Configuration config = new org.neo4j.ogm.config.Configuration(); …
0
votes
1 answer

Spring Data Neo4j example -- how to adopt it to Spring Data Neo4j v4.1

I am struggling how to convert this example: https://spring.io/guides/gs/accessing-data-neo4j/ to work on new version of Spring Data. I obviously change imports for Person.java to org.neo4j.ogm.*. I have added: @Bean public SessionFactory…
Marcin
  • 422
  • 6
  • 17
0
votes
1 answer

Neo4j save action over collection of entities

I just encountered an interesting behaviour with Spring Data for Neo4j, and I'm wondering if it is my mistake, or some strange bug. I am attempting to save the collection of neo4j entities all at once. The method signature promises to return an…
Vanja Lee
  • 263
  • 4
  • 17
0
votes
1 answer

How do I provide this countQuery to Query annotation

I'm moving my project from SDN 3 to SDN 4 and from Neo4j 2.3 to 3.0.1 I have a following Spring Data Neo4j repository method: @Query(value = "START d=node:node_auto_index({autoIndexQuery}) MATCH (d:Decision) RETURN d", countQuery = "START…
brunoid
  • 2,121
  • 2
  • 12
  • 22
0
votes
1 answer

Injecting URI in ogm.properties from environment variable (spring data neo4j)

Is there a way to inject URI in the ogm.properties (spring data neo4j) using environment variable ? e.g. URI=http://neo4j:neo4j@localhost:7474 works fine; however if I try this: URI=http://${userid}:${pwd}@${hostName}:7474 and supply those as the…
Rakesh
  • 235
  • 2
  • 10
0
votes
0 answers

Neo4j 3 SDN 4 Lucene java.lang.NoSuchMethodException: org.apache.lucene.search.BoostQuery.getField()

I'm moving from SDN 3 to SDN 4 and from Neo4j 2.3 to 3.0.1 I have a following Search Cypher query: @Query(value = "START d=node:node_auto_index({autoIndexQuery}) MATCH (d:Decision) RETURN d") Page searchDecisions(@Param("autoIndexQuery")…
brunoid
  • 2,121
  • 2
  • 12
  • 22
0
votes
1 answer

Neo4j SDN 4 node_auto_index

I'm moving from SDN 3 to SDN 4 and from Neo4j 2.3 to 3.0.1 I have a following Search Cypher query: @Query(value = "START d=node:node_auto_index({autoIndexQuery}) MATCH (d:Decision) RETURN d") Page searchDecisions(@Param("autoIndexQuery")…
brunoid
  • 2,121
  • 2
  • 12
  • 22
0
votes
1 answer

Neo4j SDN inconsistency between OEM and custom Cypher queries

While moving from SDN 3 to SDN 4 and from Neo4j 2.3 to Neo4j 3.0.1 I ran into a issue with inconsistency between OEM and custom Cypher queries. I have a following Cypher query: @Query("MATCH ()-[r]-(cg:CriterionGroup) WHERE id(cg) =…
brunoid
  • 2,121
  • 2
  • 12
  • 22
0
votes
0 answers

getSession Neo4j [NullPointerException: null]

My current configuration class Neo4jSessionFactory (implicit inj: Injector) extends Injectable { val neo4jHost = inject [String] (identified by "neo4j.server.host") val neo4jPort = inject [Integer] (identified by…
kenlz
  • 461
  • 7
  • 22