Hi,
What is the right way to clear the schema and data of a graph.
I tried the following methods.
Method 1:
graph.close(); org.janusgraph.core.util.JanusGraphCleanup.clear(graph)
After clearing later when accessing the same graph it throws random errors like "vertex id 1211 was removed" like that. Looks like the graph goes into some inconsistent state.
Method 2:
ConfiguredGraphFactory.drop()
But this method throws below error when run via gremlin shell.
Error: startup failed:
Script79.groovy: 1: [Static type checking] - Cannot find matching method org.janusgraph.core.ConfiguredGraphFactory#drop(java.lang.String). Please check if the declared type is right and if the method exists.
@ line 1, column 1.
ConfiguredGraphFactory.drop('samplegraph1')
I dont understand why the error says can not find method.
Any help is appreciated.
- Raj