How to Undo/Redo/Rollback in Neo4j? - neo4j

I have read the Neo4j Java Developer Reference Document recently, but I didn't see the information about Undo/Redo/Rollback, so I wonder is the Neo4j support these operations?

neo4j does not support undo/redo, but it does support transactions (so, rollbacks are supported).
See the specific documentation for Java, Cypher, the HTTP API, and Bolt.

Related

Neo4j using Gremlin query in .net core 3.0

We currently use gremlin.net library in a net core 3.0 application to connect to Azure Cosmos db. We would like to connect to neo4j.
Can we use same gremlin.net library for neo4j? Assuming gremlin
server is installed.
Will Neo4j.Driver library support gremlin
queries? What exact library to use?
Any code sample to connect and
create a node in neo4j using gremlin library for a .net core 3.0
application?
Is neo4j really a better graph model than Azure cosmos?
Can we use same gremlin.net library for neo4j? Assuming gremlin server is installed.
Yes, assuming you mean Gremlin.Net and yes, Gremlin Server should be installed hosting neo4j.
Will Neo4j.Driver library support gremlin queries? What exact library to use?
I don't think that's possible. Neo4j drivers will support Cypher based queries, not Gremlin.
Any code sample to connect and create a node in neo4j using gremlin library for a .net core 3.0 application?
The beauty of Gremlin is that the code examples for one graph database are the same for any other and for the most part, Gremlin in Java is the same as Gremlin in .NET or any other programming language (aside from changes that make Gremlin more ergonomic to the programming language itself). So, if you want to create a node then it's always going to be:
using static Gremlin.Net.Process.Traversal.AnonymousTraversalSource;
var g = Traversal().WithRemote(
new DriverRemoteConnection(new GremlinClient(new GremlinServer("localhost", 8182))));
g.AddV("person").Property("name","Bob").Iterate();
Is neo4j really a better graph model than Azure cosmos?
My personal opinion is that you try them both and determine which is better for yourself given you requirements. That is the choice that Apache TinkerPop and Gremlin help to give you in that you can try lots and lots of different graph systems out there to find the one best suited to your needs.

Neo4j: difference between tinkerpop gremlin and aurelius gremlin

as I was wandering in the Web looking for a Gremlin implementation for Neo4j I found these two possible solutions:
https://github.com/thinkaurelius/neo4j-gremlin-plugin
http://tinkerpop.incubator.apache.org/docs/3.0.2-incubating/#neo4j-gremlin
Does anybody know what is the difference between the two in practice?
I saw that 1. is a Neo4j plugin while it's not really clear to me what the second is, and if it would lock the entire database thus not allowing other connections (I noticed that it requires the path to the data folder).
Which one is preferred in the neo4j community?
Cheers,
Alberto
I'm not sure there's really a difference as there isn't a direct comparison to be made. The second link is to the TinkerPop project and specifically to the Neo4j implementation of TinkerPop APIs. It runs in an embedded mode and does not yet have support for HA (though we hope to have that soon). The Neo4j implementation can be run in Gremlin Server which let's you send Gremlin to it as a REST, websockets, etc endpoint.
The project in the first link you provided uses that implementation to allow you to send Gremlin to Neo4j Server - so the first project depends on the second.
Your rule of thumb should be activity in the source code.
neo4j-gremlin-plugin has 3 commits this year - https://github.com/thinkaurelius/neo4j-gremlin-plugin/commits/master
tikerpop is much more active - https://github.com/apache/incubator-tinkerpop/commits/master/neo4j-gremlin/src/main/java/org/apache/tinkerpop/gremlin/neo4j
neo4j-gremlin-plugin
Extending existing Neo4j server with support for Gremlin Query Language.
TinkerPop Neo4j-Gremlin
Extending Gremlin console with support for Neo4j server.

SOA Architecture, Android and Neo4j?

I am working on scientific project and i am currently studying the possibility to use graph databases.
The software architecture that we developed is service oriented with android clients.
I want to know if Neo4j can be used in my case and the most important if i can execute Cypher requests from Android.
Cheers
As #MarcoCI mentioned you can emit Cypher queries via REST. Neo4j therefore has the transactional Cypher endpoint and the legacy Cypher endpoint.
Another idea would be to encapsulate your actions on a use-case level within unmanaged extensions and let your Android client trigger those. Unmanaged extensions are basically java code deployed to the Neo4j server that expose new REST endpoints. Within its implementation you might use Cypher or core API.

Neo4J multi-document transactions for standalone server

I am considering Neo4J for some project. I recall reading somewhere that multi-document ACID transactions are only supported for embedded database, but not for the standalone one. Searching at the Neo4J site, I could not find any info about this. Some more information about this, or some pointers could help. Thank you.
Neo4j itself supports now transactions over the wire with 2.0
See: http://docs.neo4j.org/chunked/milestone/rest-api-transactional.html
Spring Data Neo4j does not yet and it will take a while until we get there, as it means to rewrite the core to use cypher throughout which it doesn't do now.

Neo4j Can we have programming features in quering graph database

Can we Use programming features in neo4j query like as we have pl-sql in sql. I need some loops and other programming features in Cypher query.Please can anyone tell is it possible.
Yes. You have two options
Server Plugins
Unmanaged Extensions
Server Plugins
The server’s functionality can be extended by adding plugins.
Plugins are user-specified code which extend the capabilities of the database, nodes, or relationships.
The neo4j server will then advertise the plugin functionality within representations as clients interact via HTTP.

Resources