Exports Graph with Gremlin

Why we need exports of Graph Databases?

i) Migration between Tinker pop enabled databases

ii) Creating backup copies of graph

There are three way It can be done

i) GraphML:- It is a lossy format

Syntax for writing

graph.io(IoCore.graphml()).writeGraph(“mydata.xml”)

Syntax for reading

graph.io(IoCore.graphml()).readGraph(“mydata.xml”)

ii) GraphSon:- It is a lossless format

Syntax for writing

graph.io(IoCore.graphson()).writeGraph(“mydata.json”)

Syntax for reading

graph.io(IoCore.graphson()).readGraph(“mydata.json”)

iii) Gyro: — Fast, efficient and lossless

Syntax for writing

graph.io(IoCore.gryo()).writeGraph(“mydata.kryo”)

Syntax for reading

graph.io(IoCore.gryo()).readGraph(“mydata.kryo”)

--

--