Explanation of start failure “java.lang.NoClassDefFoundError: org/neo4j/kernel/impl/logging/LogService”

Upon starting Neo4j 3.5 if one encounters the following error in the logs/neo4j.log Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component ‘org.neo4j.kernel.extension.GlobalKernelExtensions@14c16d’ failed to initialize. Please see the attached cause exception “org.neo4j.kernel.impl.logging.LogService”. at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.init(LifeSupport.java:434) at org.neo4j.kernel.lifecycle.LifeSupport.init(LifeSupport.java:66) at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:102) at org.neo4j.graphdb.facade.GraphDatabaseFacadeFactory.initFacade(GraphDatabaseFacadeFactory.java:203) … 9 more Caused… Read more →

Explore:  


Neo4j specific http request user agent strings

For those APOC commands that retrieve data using HTTP/HTTPS, and or running Cypher LOAD CSV the request will be sent with Neo4j specific user-agent/browser identifiers. Below is an example log from an Apache webservers access log at /var/log/apache2/access.log and includes… Read more →

Explore:  


Understanding transaction and lock timeouts

One way to handle runaway queries is to impose a time limit that will terminate a query when exceeded. There are some subtleties here that need to be understood to ensure proper behavior and avoid confusion. Defining a transaction timeout… Read more →

Explore:  


How do I compare two graphs for equality

If you are looking to compare 2 graphs (or sub-graphs) to determine if they are equivalent, the following Cypher will produce a md5sum of the nodes and properties to make that comparison. For example, you may wish to compare a… Read more →

Explore:  


Using apoc.load.jsonParams to load data from Zendesk into Neo4j to learn about article subscribers

The following document describes how to utilize the Zendesk API to load data from Zendesk into Neo4j, specifically data about users who have choosen to subscribe/follow Knowledge Base section(s). This document attempts to solve the issue described by the following… Read more →

Explore:  


How do I pass parameters when calling apoc.cypher.runFile

APOC allows one to have a stored procedure, apoc.cypher.runFile, to then run the contents of the file to the Cypher engine. To allow the reading of the file in the conf/neo4j.conf one needs to define apoc.import.file.enabled=true and then if one… Read more →

Explore:  


Using APOC to parse JSON results from Trello API

Prior to Neo4j 3.0, if you wanted to parse the JSON results from a call to a Web API, it would require you use one of the database drivers to fetch and parse the JSON data. This is described here.… Read more →

Explore:  


Explanation of error NoClassDefFoundError: org/neo4j/kernel/impl/util/JobScheduler

Upon upgrading to Neo4j 3.3, if you were previously using APOC, and did not download and install the version of APOC for 3.3 bin\neo4j start will fail. The contents of your $NEO4J_HOME/logs/neo4j.log will appear similar to. 2017-11-07 20:38:38.245+0000 INFO Bolt… Read more →

Explore:  


Working with streaks in Cypher

When using Cypher for data analysis, you might have a problem where you need to identify or filter based upon some kind of streak. For example, for a sports graph, you might want to know the maximum number of consecutive… Read more →

Explore:  


Conditional Cypher Execution

At some point you’re going to write a Cypher query requiring some conditional logic, where you want different Cypher statements executed depending on the case. At this point in time Cypher does not include native conditional functionality to address this… Read more →

Explore:  


Viewing schema data with APOC Procedures

APOC Procedures offers meta procedures to view information about your database schema and the data it stores. The procedure apoc.meta.schema() uses a sampling of the graph data to produce a map of metadata on the graph labels, relationships, properties, and… Read more →

Explore:  


How do I display date and time of when neo4j was started and other metrics

The following Cypher will utilize the JMX metrics as part of 3.1 Enterprise and display the date/time when Neo4j was started. CALL dbms.queryJmx(“org.neo4j:instance=kernel#0,name=Kernel”) yield attributes with keys(attributes) as k , attributes unwind k as row return row, case row when… Read more →

Explore:  


Using Cypher and APOC to move a property value to a label

Commencing with Neo4j 3.0 and the introduction of stored procedures as well as APOC one can utilize the stored procedure apoc.create.addLabels to move a property to a label with Cypher as follows // create a node with property studio create… Read more →

Explore:  


How to check for time range overlap in Cypher

Neo4j 3.4 introduced temporal types into Cypher, so now we have dates, dateTimes, and their local versions, too, as well as durations. While we don’t have a type for time ranges, we can use two temporal instants as the start… Read more →

Explore:  


How does apoc.periodic.iterate work with resources?

How does apoc.periodic.iterate work? For example, when running call apoc.periodic.iterate(“MATCH (n) RETURN n”, “DETACH DELETE n”, {batchSize:1000}) does it append a LIMIT to the MATCH RETURN so that it only returns the batchSize or does it return everything but it… Read more →

Explore:  


Achieving longestPath Using Cypher

While Cypher is optimized for finding the shortest path between two nodes, with such functionality as shortestPath(), it does not have the same sort of function for longest path. In some cases, you may want this, and not the shortest… Read more →

Explore:  


Explanation of error: procedure is not available due to having restricted access rights, check configuration

Commencing with Neo4j 3.2 when running a stored procedure, for example call apoc.warmup.run(); this may error with apoc.warmup.run is not available due to having restricted access rights, check configuration. The cause of this error is as a result of not… Read more →

Explore: