spring-data-neo4j

Spring Data REST Neo4j create a relationship

天大地大妈咪最大 提交于 2019-12-24 00:20:05
问题 I'm building a little test app as a way to learn Angular and refresh myself on a lot of the Spring stack. I have some minor experience with Neo4J, but the app idea has ground with a graph db like Neo4j. The idea is pretty simple, a ui to create characters and stories, and relate the characters to the stories and each other, map their individual versions of a story and create some graphs that show the character interactions to help write the overall narrative. I've got nodes for the characters

SDN with Neo4j 2.2x

我与影子孤独终老i 提交于 2019-12-23 09:20:02
问题 Many are claiming that the SDN version 3.3.1 or 4.0.0.RC1 should work with neo4j 2.2.x but I could not make it to work. I have this spring config configuration: <?xml version="1.0" encoding="UTF-8" standalone="no"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:context="http://www.springframework.org/schema/context" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:neo4j="http://www.springframework.org/schema/data/neo4j" xmlns:tx="http://www.springframework.org

Log cypher queries

依然范特西╮ 提交于 2019-12-23 05:01:36
问题 Is there a way to log cypher queries that get generated when we use spring jpa inbuilt queries like findById!? I have a complex inbuilt query whose cypher I need to see 回答1: Neo4j provides the ability to log all executed queries. Per https://neo4j.com/docs/operations-manual/current/monitoring/logging/query-logging: Neo4j can be configured to log queries executed in the database. Query logging must be enabled by setting the dbms.logs.query.enabled parameter to true. The parameter dbms.logs

Log cypher queries

余生长醉 提交于 2019-12-23 05:01:17
问题 Is there a way to log cypher queries that get generated when we use spring jpa inbuilt queries like findById!? I have a complex inbuilt query whose cypher I need to see 回答1: Neo4j provides the ability to log all executed queries. Per https://neo4j.com/docs/operations-manual/current/monitoring/logging/query-logging: Neo4j can be configured to log queries executed in the database. Query logging must be enabled by setting the dbms.logs.query.enabled parameter to true. The parameter dbms.logs

Getting dynamic values from neo4j using Spring data

房东的猫 提交于 2019-12-23 04:45:49
问题 public interface WayPointRepository extends GraphRepository, NamedIndexRepository, RelationshipOperationsRepository { @Query( value = "start point=node:waypoints(\"name:{name1}\") return point", elementClass=WayPoint.class, type=QueryType.Cypher ) public List getWayPointByName(@Param("name1") String name); } i have a neo4j database with some points stored in it with index "waypoints", i want to get some points dynamically after passing some points. for this i have created placeholder {name1},

Naming convention for bidirectional relationships in Neo4j (using Spring Data)

自闭症网瘾萝莉.ら 提交于 2019-12-23 04:24:50
问题 I need some advice to give name to relationships. Plus, I'm not sure on how I have to annotate my domain entities with spring data. Most of examples that I've seen are unidirectional and the name chosen are pretty straightforward. Supose the following example: @NodeEntity public class Person { @Indexed private String name; @RelatedTo(type="OWNS", direction=Direction.OUTGOING) private Set<Car> cars; } The relationship name seems ok, no problem. Now suppose that I want to make this relationship

RabbitMQ Spring Boot Session Error

旧城冷巷雨未停 提交于 2019-12-22 12:41:12
问题 I am running into an issue when trying to pass a RabbitMQ queue message to my Spring Boot application. I am running spring data 4 and am using Neo4j as my database. I am able to recieve and parse a JSON string from the RabbitMQ queue to the spring boot app. Here is the thread change for the receiver process: 14:19:17.811 [main] INFO o.s.b.c.e.t.TomcatEmbeddedServletContainer - Tomcat started on port(s): 8080 (http) 14:19:17.813 [main] INFO org.directoryx.Application - Started Application in 4

Passing optional parameters to @Query of a Spring Data Repository method

早过忘川 提交于 2019-12-22 07:47:06
问题 I work with Spring Data and Neo4j in my current project and have the following situation: @RestController @RequestMapping(value = SearchResource.URI) public class PersonResource { public static final String URI = "/person"; @Autowired PersonRepository personRepository; @GetMapping public Collection<Person> findPersons( @RequestParam(value = "name", required = false) String name, @RequestParam(value = "birthDate", required = false) Long birthDate, @RequestParam(value = "town", required = false

DynamicProperties in Spring Data Neo4j 4

落花浮王杯 提交于 2019-12-22 06:46:57
问题 I'm using DynamicProperties of Spring Data Neo4j 3.x. I'm missing this class in Spring Data Neo4j 4.0.0.M1 (SDN4). I there a new concept in SDN4 to store dynamic property values? A DynamicProperties property on a @NodeEntity stores all its properties dynamically on the underlying node itself. The key/value pairs of the DynamicProperties member are stored on the node with the keys prefixed with the property name that is returned by DelegatingFieldAccessorFactory#getNeo4jPropertyName(Field) .

Neo4j Multi-tenancy

左心房为你撑大大i 提交于 2019-12-22 05:03:15
问题 What is the best way to achieve multi-tenancy in neo4j? I have seen Tinkerpop and Spring Data. I'm have multiple clients and I would like to store client info in its own database to ensure security. I do not want to use labels or indexes to solve this problem. 回答1: You mention that you've "seen TinkerPop" but I couldn't tell if that meant you've seen it, considered it and dismissed it as a solution here, so apologies if that is the case and I'm not answering your question. I've successfully