TinkerPop integration

Since BigConnect uses a native graph-based data model, it's just normal to think of Apache TinkerPop. For those that don't know, Apache TinkerPop™ is a graph computing framework for both graph databases (OLTP) and graph analytic systems (OLAP). The integration code is located in a new GitHub repository named bc-gremlin and is currently a working version.

All Gremlin traversal predicates are being pushed down to BigConnect, which in turn pushes them down to the search index, so numeric comparisons, text and geo matching should be really fast.

To get started, here is a step-by-step guide to launch a Gremlin Console on a BigConnect Graph.

  1. Download and unzip the Gremlin Console 3.4.0 from https://www.apache.org/dyn/closer.lua/tinkerpop/3.4.0/apache-tinkerpop-gremlin-console-3.4.0-bin.zip
  2. Clone the bc-gremlin GitHub repository: git clone https://github.com/mware-solutions/bc-gremlin.git
  3. Inside the bc-gremlin folder run mvn -Pgenerate-deps package
  4. Copy all jars from target/lib to the Gremlin Console installation folder, inside ext/bigconnect/plugin
  5. Copy target/bc-gremlin-0.9.jar to the Gremlin Console installation folder, inside ext/bigconnect/lib
  6. Inside the Gremlin Console installation folder, create a file named bc.properties inside the conf/ folder, with the following content:
  1. Start the Gremlin Console using bin/gremlin.sh
  2. Activate the BigConnect plugin:
:plugin use bigconnectgraph = GraphFactory.open('conf/bc.properties')g = graph.traversal()
  1. Create a sample graph:
  1. Start querying

You can do the same thing from Java. Just add bc-gremlin as a Maven dependency to your project and create a new TinkerPop graph using the following sample code:

CODE: https://gist.github.com/flaviusburca/a35429b64e699ae67793d6a93a5e0096.js

Back to Blog