From 7da8051333dbe4a21b13c43ea7f297b876e60e2b Mon Sep 17 00:00:00 2001 From: Michael Hunger Date: Fri, 18 Mar 2011 15:13:49 +0100 Subject: [PATCH] documentation updates --- src/docbkx/index.xml | 18 ++++++++--------- src/docbkx/reference/performance.xml | 29 ++++++++++++++++++++++++++-- 2 files changed, 36 insertions(+), 11 deletions(-) diff --git a/src/docbkx/index.xml b/src/docbkx/index.xml index 036e7f31b..906cf69f6 100644 --- a/src/docbkx/index.xml +++ b/src/docbkx/index.xml @@ -41,7 +41,7 @@ - + Reference @@ -56,12 +56,12 @@ - - - - - - - - + + + + + + + + diff --git a/src/docbkx/reference/performance.xml b/src/docbkx/reference/performance.xml index e1832cfd9..5bfa652d6 100644 --- a/src/docbkx/reference/performance.xml +++ b/src/docbkx/reference/performance.xml @@ -3,12 +3,37 @@ Performance considerations - ... + Although adding another layer of abstraction is always the solution to look for in software development, + each of those layers adds overhead and performance penalties. This chapter discusses the performance + implications of using Spring Data Graph on top of the native Neo4j API.
When to use SDG? - ... + The focus of Spring Data Graph is to add a convenience layer on top of the native Neo4j API. This should + enable developers to get up and running with the graph database very quickly, having their domain objects + mapped to the graph. Building on this foundation one can later explore other, more efficient ways to + explore and process the graph - if the performance requirements demand it. + + + Like any other object mapping framework, the domain entities that are created, read or persisted represent + only a small fraction of the data stored in the database. This is the set needed for a certain use-case to + be displayed, edited or processed in a low throughput fashion. The main advantages of using an object mapper + in this case is the ease of use of real domain objects in your business logic and also with existing + frameworks and libraries that expect Java POJOs as input or create them as results. + + + Spring Data Graph was not designed with a major performance focus. It adds some overhead to pure graph operations. + Something to keep in mind is, that the access of properties and relationships is a read trough in the attached + case. So to avoid multiple read-throughs it is sensible to store the result in a local variable at the scope of + use (method, class or jsp for example). + + + Most of the overhead comes from the use of the Java Reflection API, which is leveraged to provide information about Annotations, Fields and Constructors. + Some of the information is already cached by the JVM and the library, so that only the first access gets a + performance penalty. + +