After Spring Data Neo4j 4 which was a complete rewrite, Spring Data Neo4j 5 is major version bringing lots of new functionnalities. If Spring is not your thing, the underlying Object-Graph Mapper can be used on its own from any JVM language.
Development of Spring Data integration started in early stages of Neo4j, by Rod Johnson and Emil Eifrem. The project was then carried on at Neo Technology by Michael Hunger and others, seeing its first General Availability (GA) release in 2010 when Neo4j was an embedded Java only database. In order to fully embrace the modern architecture of Neo4j (server mode, official drivers and Cypher query language), and to integrate the many improvements in the Spring ecosystem, after version 3 a complete re-write of the library was planned.
In September 2014, the first lines of code were written by the GraphAware team under the leadership of Neo Technology and in close cooperation with the Spring project team. After a year of full-time development GA release was launched in September 2015. Since then we continued to improve code and documentation, adding features, and supporting new versions of Neo4j. Current (GA) version is 5.0.0, released in October 2017, and we are working on features for future releases.
Building Spring Data Neo4j 4.1 Applications Like A Superhero at GraphConnect 2016
GraphAware would like to thank the following people and organisations involved in SDN efforts.
the man behind Spring Data project who makes every release of SDN happen under the Spring umbrella
the guru behind the first 3 versions of SDN who tirelessly keeps supporting the SDN efforts
we couldn’t have done it without the doctor’s wisdom, supervision and guidance
for making sure that the OGM builds and releases work like a charm
Who is currently involved from the GraphAware team
Principal Consultant, GraphAware
Vince is the main author and mastermind behind the OGM. He led the SDN4 project from the very beginning in September 2014 designing the architecture and guiding the rest of the GraphAware team. Vince has been instrumental in driving the adoption of SDN4, introducing the framework through webinars and Neo4j User Groups as well as presenting it at conferences, such as Spring IO Barcelona and GraphConnect.
Principal Consultant, GraphAware
Luanne joined forces with the SDN4 team in February 2015. She gradually assumed a full-time, active leadership role, and successfully took the project to RC1 release in July and RC2 release in August. Luanne has published a popular, educational blogpost on AirPair and her contributions on StackOverflow are unrivalled. She recently presented SDN 4.1 at GraphConnect 2016.
Senior Consultant, GraphAware
Nicolas is a long term user of the Spring framework, and the Spring Data projects. He joined GraphAware to work on new features of SDN 5. Nicolas helps people on StackOverflow and Slack, and also talks about SDN during meetups and java user groups.
Senior Consultant, GraphAware
František is an experienced SDN user who has been using Neo4j and SDN since 2013. He joined SDN team in May 2017 to improve the user experience for developers using the framework. He is also active on StackOverflow and neo4j-users slack channel where he helps people with SDN issues.
SDN5 fun stats
Lines of code
Total Effort (man-days)
Why to use SDN
Simple Neo4j applications start off as PoCs and often begin using the low level Neo4j driver to run Cypher queries directly against the graph. As the size of the project gets bigger, or if the ability to add graph capabilities to an existing enterprise application is required, this approach shows its limitations as effort to maintain the application and produce hand rolled queries and object mapping increases radically.
Using Spring Data Neo4j, developers can focus on the domain model and business logic, relying on the robust and optimized CRUD set of functionalities provided by the Neo4j Object Graph Mapper (OGM). This is a powerful library that maps rich domain objects and references to graph nodes and relationships using Cypher statements, in a fast and smart manner. For applications built with Spring or Spring Boot frameworks, SDN4 provides advanced integrations that gets teams up to speed in no time, and with significantly reduced effort.
For companies already committed to the Spring ecosystem, SDN is the most straightforward way to implement the Neo4j graph database. However, if you are building standalone Neo4j backend applications or highly scalable, cloud based JVM applications with complex api-centric microservices architecture, Spring and Spring Data Neo4j give you the production ready framework you need and GraphAware is here to help you reach your goals!
Who uses SDN?
SDN is used in production by organizations of all size, including some of the world’s Fortune 500 companies.
When not to use SDN?
As consultants we also advise companies when not to use SDN/OGM. From experience we know there are some cases when it doesn’t make sense to use object-graph mapping, and other options should be considered instead.
- When the main task is to bulk import data into a graph, SDN is not the right tool for the job, and another ETL tool is a better choice.
- When domain objects greatly differ from the graph model and significant impedance mismatch is generated (e.g. when complex objects are destructured into their components, and the graph logic is based on the connected components, but the application always uses the full objects)
- When your application is mostly built on complex graph operations that require complex Cypher queries. In these last two scenarios, complete custom solutions should be considered.
In all cases, at GraphAware we can help you find or build the right tool for the job.
Easy and robust
- Annotation based mapping of domain entities to/from graph database nodes, relationships and properties
- Standard CRUD operations, with exception translation and transaction management
- Extensive Spring Data Commons Repositories Support, including annotated and derived finder methods, paging and sorting, stream and async
- Common and custom data types conversion
- Simple configuration.
Fast and smart
- Fast metadata scanning to transfer your domain model into the graph
- Read and write variable-depth persistence for immediate loading and updating of the neighborhood of a node
- Smart object-mapping (with delta tracking) to reduce redundant requests to the database, improve latency and minimise wasted CPU cycles
- Persistence events, related both to top-level as well as connected objects.
Flexible and complete
- Decoupled OGM, allows to use the mapping layer independently of Spring Framework
- Supports binary (bolt), http and embedded transports to connect to Neo4j
- Supports Cypher Graph Query Language and custom queries
- Spring Boot (yes, you can use the Spring Initializr to bootstrap your application!)
- Support for Neo4j clusters (High Availability and Causal Clustering)
Help, Feedback and Community
We encourage all SDN users to be active members of the community and we give support and exchange ideas on multiple channels:
- Ask and answer questions on StackOverflow using spring-data-neo4j or neo4j-ogm tag
- Get interactive help and exchange feedback using the sdn-ogm channel in neo4j-users slack (go to neo4j.com/slack to get your invite)
- File an issue on JIRA Spring's Issue Tracker
- Find the source code on Github
- Best updated source of information on how to use SDN5 is the project documentation
- SDN and OGM pages in Neo4j website contain links to spring projects (with quick start guides), code repositories, documentation, changelogs, tutorials, videos and examples
- Check out also other SDN resources from our blog and website.
How can GraphAware help?
As core committers to the SDN framework, we are ready to help companies who are considering the use of SDN or are planning to upgrade from previous versions. We also provide custom trainings focused on the Spring Data framework and Neo4j. These services are delivered by our Neo4j Certified Professionals, some of whom are also SpringSource Certified Spring trainers.Get in touch