This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@POST | |
@Path("/{id}") | |
public Response postVertex(@PathParam("graphname") String graphName, @PathParam("id") String id) { | |
Graph graph = this.getRexsterApplicationGraph(graphName).getGraph(); | |
Vertex vertex = null; | |
try { | |
vertex = graph.getVertex(id); | |
} catch (RuntimeException re) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## post an edge | |
curl -d "" -v http://localhost:8182/graphs/dexsample/edges?_outV=1024\&_inV=1025\&_label=friend | |
curl -v -X POST -H "Content-Type:application/json" -d '{name:"willa"}' http://localhost:8182/graphs/tinkergraph/vertices/100 | |
curl -v -d 'age=(integer,100)' -X POST http://localhost:8182/graphs/tinkergraph/vertices/1 | |
curl -v -d 'age=(list,((i,100)))' -X POST http://localhost:8182/graphs/tinkergraph/vertices/1 | |
curl -v -X POST -H "Content-Type:application/json" -d '{"script":"g.v(1)"}' http://localhost:8182/graphs/tinkergraph/tp/gremlin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for i in {1..1000} | |
do | |
echo "[graph] fire $i" >> log.txt | |
curl -v http://localhost:8182/neo4jsample >> log.txt | |
echo "" >> log.txt | |
done | |
for i in {1..1000} | |
do | |
echo "[vertices] fire $i" >> log.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"graph": { | |
"vertices": [ | |
{ | |
"name": "lop", | |
"lang": "java", | |
"_id": "3", | |
"_type": "vertex" | |
}, | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.3/jquery.min.js"></script> | |
<script type="text/javascript"> | |
$(function() { | |
$.ajax({ | |
type: "PUT", | |
url: "http://localhost:8182/graphs/tinkergraph/vertices/1", | |
data: "name=John&location=Boston", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# first curl "warms" the service...second curl is the timed test | |
curl -s http://localhost:8182/graphs/gratefulgraph/{vertices/1,edges/0} | |
time curl -s http://localhost:8182/graphs/gratefulgraph/vertices/[0-808] http://localhost:8182/graphs/gratefulgraph/edges/[0-8048] | |
# 0.6 | |
real 0m34.979s | |
user 0m1.170s | |
sys 0m0.690s | |
# 0.7-SNAPSHOT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Make sure all the change Wiki pages are in the form they should be for release (ie. change the main wiki page to have the <dependency> point to the latest version. change the main Wiki page to have the JavaDoc pointer point to where the latest version JavaDoc will be (for library projects only).) | |
2. bump the pom.xml of the project (requires the bumping of all depended on TinkerPop projects too) - for Gremlin and Rexster the Tokens.java public static String VERSION needs to be bumped | |
X. ant release -Drelease.version=0.7 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var jitJson = _(graphson.graph.vertices).map(function (v, key) { | |
return { | |
id: v._id, | |
name: v[nameKey], | |
data: v, | |
adjacencies: _(graphson.graph.edges).filter(function (e) { return e._outV == v._id }).map(function (edge, key) { | |
return { | |
nodeTo: edge._inV, | |
data: edge | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void testTransactionInTransaction() { | |
TransactionalGraph graph = (TransactionalGraph) graphTest.getGraphInstance(); | |
for (int i = 0; i < 100; i++) { | |
final Vertex v1 = graph.addVertex(null); | |
final Vertex v2 = graph.addVertex(null); | |
graph.setMaxBufferSize(0); | |
graph.startTransaction(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -v -X POST http://localhost:8182/graphs/neo4jsample/indices/vft?class=vertex&type=automatic¶ms.to_lower_case=true¶ms.type=fulltext¶ms.provider=lucene | |
curl -v -d -X POST http://localhost:8182/graphs/neo4jsample/vertices?name=Willy | |
curl -v http://localhost:8182/graphs/neo4jsample/indices/vft?key=name&value=%25query%25willy |
OlderNewer