You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by sp...@apache.org on 2018/02/08 16:02:52 UTC

[1/6] tinkerpop git commit: TINKERPOP-1877 Added the "kitchen sink" toy graph

Repository: tinkerpop
Updated Branches:
  refs/heads/master f5d67e4a4 -> 304a7ae3f


TINKERPOP-1877 Added the "kitchen sink" toy graph

Contains a single self-loop subgraph at this point.


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/5f67d9c8
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/5f67d9c8
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/5f67d9c8

Branch: refs/heads/master
Commit: 5f67d9c88cf637984a2982b4beeda9134eb01fe5
Parents: 0f58b7c
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Wed Jan 31 10:46:22 2018 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Wed Jan 31 10:46:22 2018 -0500

----------------------------------------------------------------------
 CHANGELOG.asciidoc                              |   1 +
 data/tinkerpop-sink-typed.json                  |   1 +
 data/tinkerpop-sink-v2d0-typed.json             |   1 +
 data/tinkerpop-sink-v2d0.json                   |   1 +
 data/tinkerpop-sink.json                        |   1 +
 data/tinkerpop-sink.kryo                        | Bin 0 -> 76 bytes
 .../upgrade/release-3.2.x-incubating.asciidoc   |  24 ++++++++-
 .../step/branch/GroovyRepeatTest.groovy         |   5 ++
 gremlin-server/scripts/generate-all.groovy      |   6 ++-
 .../driver/remote/RemoteGraphProvider.java      |   7 +--
 .../remote/gremlin-server-integration.yaml      |   3 +-
 .../apache/tinkerpop/gremlin/LoadGraphWith.java |  16 +++++-
 .../apache/tinkerpop/gremlin/TestHelper.java    |   3 +-
 .../traversal/step/branch/RepeatTest.java       |  25 ++++++++-
 .../io/graphson/tinkerpop-sink-typed.json       |   1 +
 .../io/graphson/tinkerpop-sink-v2d0-typed.json  |   1 +
 .../io/graphson/tinkerpop-sink-v2d0.json        |   1 +
 .../structure/io/graphson/tinkerpop-sink.json   |   1 +
 .../structure/io/gryo/tinkerpop-sink.kryo       | Bin 0 -> 76 bytes
 .../gremlin/hadoop/HadoopGraphProvider.java     |  10 ++--
 .../tinkergraph/structure/TinkerFactory.java    |  15 ++++++
 .../tinkergraph/TinkerGraphProvider.java        |   2 +
 .../structure/IoDataGenerationTest.java         |  53 +++++++++++++++++++
 23 files changed, 162 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/CHANGELOG.asciidoc
----------------------------------------------------------------------
diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc
index 938fc68..c562ccd 100644
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@ -23,6 +23,7 @@ image::https://raw.githubusercontent.com/apache/tinkerpop/master/docs/static/ima
 [[release-3-2-8]]
 === TinkerPop 3.2.8 (Release Date: NOT OFFICIALLY RELEASED YET)
 
+* Added the "Kitchen Sink" test data set.
 * Fixed a bug in `NumberHelper` that led to wrong min/max results if numbers exceeded the Integer limits.
 * Delayed setting of the request identifier until `RequestMessage` construction by the builder.
 * Removed hardcoded expectation in metrics serialization test suite as different providers may have different outputs.

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/data/tinkerpop-sink-typed.json
----------------------------------------------------------------------
diff --git a/data/tinkerpop-sink-typed.json b/data/tinkerpop-sink-typed.json
new file mode 100644
index 0000000..f62a717
--- /dev/null
+++ b/data/tinkerpop-sink-typed.json
@@ -0,0 +1 @@
+{"@class":"java.util.HashMap","id":["java.lang.Long",0],"label":"loops","inE":{"@class":"java.util.HashMap","self":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",2],"outV":["java.lang.Long",0]}]]},"outE":{"@class":"java.util.HashMap","self":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",2],"inV":["java.lang.Long",0]}]]},"properties":{"@class":"java.util.HashMap","name":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",1],"value":"loop"}]]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/data/tinkerpop-sink-v2d0-typed.json
----------------------------------------------------------------------
diff --git a/data/tinkerpop-sink-v2d0-typed.json b/data/tinkerpop-sink-v2d0-typed.json
new file mode 100644
index 0000000..df22167
--- /dev/null
+++ b/data/tinkerpop-sink-v2d0-typed.json
@@ -0,0 +1 @@
+{"id":{"@type":"g:Int64","@value":0},"label":"loops","inE":{"self":[{"id":{"@type":"g:Int64","@value":2},"outV":{"@type":"g:Int64","@value":0}}]},"outE":{"self":[{"id":{"@type":"g:Int64","@value":2},"inV":{"@type":"g:Int64","@value":0}}]},"properties":{"name":[{"id":{"@type":"g:Int64","@value":1},"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/data/tinkerpop-sink-v2d0.json
----------------------------------------------------------------------
diff --git a/data/tinkerpop-sink-v2d0.json b/data/tinkerpop-sink-v2d0.json
new file mode 100644
index 0000000..39496ba
--- /dev/null
+++ b/data/tinkerpop-sink-v2d0.json
@@ -0,0 +1 @@
+{"id":0,"label":"loops","inE":{"self":[{"id":2,"outV":0}]},"outE":{"self":[{"id":2,"inV":0}]},"properties":{"name":[{"id":1,"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/data/tinkerpop-sink.json
----------------------------------------------------------------------
diff --git a/data/tinkerpop-sink.json b/data/tinkerpop-sink.json
new file mode 100644
index 0000000..39496ba
--- /dev/null
+++ b/data/tinkerpop-sink.json
@@ -0,0 +1 @@
+{"id":0,"label":"loops","inE":{"self":[{"id":2,"outV":0}]},"outE":{"self":[{"id":2,"inV":0}]},"properties":{"name":[{"id":1,"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/data/tinkerpop-sink.kryo
----------------------------------------------------------------------
diff --git a/data/tinkerpop-sink.kryo b/data/tinkerpop-sink.kryo
new file mode 100644
index 0000000..9a26e15
Binary files /dev/null and b/data/tinkerpop-sink.kryo differ

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/docs/src/upgrade/release-3.2.x-incubating.asciidoc
----------------------------------------------------------------------
diff --git a/docs/src/upgrade/release-3.2.x-incubating.asciidoc b/docs/src/upgrade/release-3.2.x-incubating.asciidoc
index bef13ed..00a6e83 100644
--- a/docs/src/upgrade/release-3.2.x-incubating.asciidoc
+++ b/docs/src/upgrade/release-3.2.x-incubating.asciidoc
@@ -21,14 +21,34 @@ image::https://raw.githubusercontent.com/apache/tinkerpop/master/docs/static/ima
 
 *Nine Inch Gremlins*
 
+== TinkerPop 3.2.8
+
+*Release Date: NOT OFFICIALLY RELEASED YET*
+
+Please see the link:https://github.com/apache/tinkerpop/blob/3.2.8/CHANGELOG.asciidoc#release-3-2-8[changelog] for a complete list of all the modifications that are part of this release.
+
+=== Upgrading for Providers
+
+==== Graph System Providers
+
+===== Kitchen Sink Test Graph
+
+The "Kitchen Sink" test graph has been added to the `gremlin-test` module. It contains (or will contain) various
+disconnected subgraphs of that offer unique structures (e.g. a self-loop) for specific test cases. Graph systems that
+use the test suite should not have to make any changes to account for this new graph unless that system performs some
+form or special pre-initialization of their system in preparation for loading (e.g. requires a schema) or does the
+loading of the graph test data outside of the standard method in which TinkerPop provides.
+
+See: link:https://issues.apache.org/jira/browse/TINKERPOP-1877[TINKERPOP-1877]
+
 == TinkerPop 3.2.7
 
 *Release Date: December 17, 2017*
 
-=== Upgrading for Users
-
 Please see the link:https://github.com/apache/tinkerpop/blob/3.2.7/CHANGELOG.asciidoc#release-3-2-7[changelog] for a complete list of all the modifications that are part of this release.
 
+=== Upgrading for Users
+
 ==== Gremlin-Python Core Types
 With the addition of `UUID`, `Date`, and `Timestamp`, Gremlin-Python now implements serializers for all core GraphSON types. Users
 that were using other types to represent this data can now use the Python classes `datetime.datetime` and`uuid.UUID` in GLV traversals.

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/branch/GroovyRepeatTest.groovy
----------------------------------------------------------------------
diff --git a/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/branch/GroovyRepeatTest.groovy b/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/branch/GroovyRepeatTest.groovy
index 3c366dc..581c511 100644
--- a/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/branch/GroovyRepeatTest.groovy
+++ b/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/branch/GroovyRepeatTest.groovy
@@ -102,5 +102,10 @@ public abstract class GroovyRepeatTest {
         public Traversal<Vertex, Path> get_g_V_hasXname_markoX_repeatXoutE_inV_simplePathX_untilXhasXname_rippleXX_path_byXnameX_byXlabelX() {
             new ScriptTraversal<>(g, "gremlin-groovy", "g.V.has('name', 'marko').repeat(__.outE.inV.simplePath).until(has('name', 'ripple')).path.by('name').by(label)")
         }
+
+        @Override
+        public Traversal<Vertex, Path> get_g_V_hasXloop_name_loopX_repeatXinX_timesX5X_path_by_name() {
+            new ScriptTraversal<>(g, "gremlin-groovy", "g.V().has('loops','name','loop').repeat(__.in()).times(5).path().by('name')")
+        }
     }
 }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-server/scripts/generate-all.groovy
----------------------------------------------------------------------
diff --git a/gremlin-server/scripts/generate-all.groovy b/gremlin-server/scripts/generate-all.groovy
index 6b88b2b..66b1cb4 100644
--- a/gremlin-server/scripts/generate-all.groovy
+++ b/gremlin-server/scripts/generate-all.groovy
@@ -28,6 +28,7 @@ globals << [hook : [
     TinkerFactory.generateModern(modern)
     TinkerFactory.generateTheCrew(crew)
     grateful.io(gryo()).readGraph('../data/grateful-dead.kryo')
+    TinkerFactory.generateKitchenSink(sink)
 
     // a wild bit of trickery here. the process tests use an INTEGER id manager when LoadGraphWith is used. this
     // closure provides a way to to manually override the various id managers for TinkerGraph - the graph on which
@@ -45,7 +46,7 @@ globals << [hook : [
         idManagerField.set(graph, TinkerGraph.DefaultIdManager.INTEGER)
     }
 
-    [classic, modern, crew].each{
+    [classic, modern, crew, sink].each{
       allowSetOfIdManager(it, "vertexIdManager")
       allowSetOfIdManager(it, "edgeIdManager")
       allowSetOfIdManager(it, "vertexPropertyIdManager")
@@ -58,4 +59,5 @@ globals << [gclassic : classic.traversal()]
 globals << [gmodern : modern.traversal()]
 globals << [gcrew : crew.traversal()]
 globals << [ggraph : graph.traversal()]
-globals << [ggrateful : grateful.traversal()]
\ No newline at end of file
+globals << [ggrateful : grateful.traversal()]
+globals << [gsink : sink.traversal()]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/driver/remote/RemoteGraphProvider.java
----------------------------------------------------------------------
diff --git a/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/driver/remote/RemoteGraphProvider.java b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/driver/remote/RemoteGraphProvider.java
index ab0093d..2c81078 100644
--- a/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/driver/remote/RemoteGraphProvider.java
+++ b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/driver/remote/RemoteGraphProvider.java
@@ -23,7 +23,6 @@ import org.apache.tinkerpop.gremlin.AbstractGraphProvider;
 import org.apache.tinkerpop.gremlin.LoadGraphWith;
 import org.apache.tinkerpop.gremlin.driver.Client;
 import org.apache.tinkerpop.gremlin.driver.Cluster;
-import org.apache.tinkerpop.gremlin.driver.ser.Serializers;
 import org.apache.tinkerpop.gremlin.process.remote.RemoteGraph;
 import org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversalSource;
 import org.apache.tinkerpop.gremlin.server.GremlinServer;
@@ -51,7 +50,6 @@ public class RemoteGraphProvider extends AbstractGraphProvider implements AutoCl
     private static GremlinServer server;
     private final Map<String, RemoteGraph> remoteCache = new HashMap<>();
     private final Cluster cluster = TestClientFactory.open();
-    //private final Cluster cluster = Cluster.build().maxContentLength(1024000).serializer(Serializers.GRAPHSON_V2D0).create();
     private final Client client = cluster.connect();
 
     public RemoteGraphProvider() {
@@ -96,7 +94,7 @@ public class RemoteGraphProvider extends AbstractGraphProvider implements AutoCl
 
     @Override
     public void clear(final Graph graph, final Configuration configuration) throws Exception {
-        // doesn't bother to clear grateful because i don't believe that ever gets mutated - read-only
+        // doesn't bother to clear grateful/sink because i don't believe that ever gets mutated - read-only
         client.submit("classic.clear();modern.clear();crew.clear();graph.clear();" +
                 "TinkerFactory.generateClassic(classic);" +
                 "TinkerFactory.generateModern(modern);" +
@@ -159,6 +157,9 @@ public class RemoteGraphProvider extends AbstractGraphProvider implements AutoCl
             case CREW:
                 serverGraphName = "crew";
                 break;
+            case SINK:
+                serverGraphName = "sink";
+                break;
             default:
                 serverGraphName = "graph";
                 break;

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
----------------------------------------------------------------------
diff --git a/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml b/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
index d1e7ba6..28ea1ac 100644
--- a/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
+++ b/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
@@ -23,7 +23,8 @@ graphs: {
   classic: conf/tinkergraph-empty.properties,
   modern: conf/tinkergraph-empty.properties,
   crew: conf/tinkergraph-empty.properties,
-  grateful: conf/tinkergraph-empty.properties}
+  grateful: conf/tinkergraph-empty.properties,
+  sink: conf/tinkergraph-empty.properties}
 plugins:
   - tinkerpop.tinkergraph
 scriptEngines: {

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
index 071d579..9fc2056 100644
--- a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
+++ b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
@@ -77,7 +77,13 @@ public @interface LoadGraphWith {
          * Loads the "grateful dead" graph which is a "large" graph which provides for the construction of more
          * complex traversals.
          */
-        GRATEFUL;
+        GRATEFUL,
+
+        /**
+         * Loads a test graph which contains disconnected subgraphs specialized for testing purposes (e.g. a subgraph
+         * with a self-loop). This graph is created with the {@link TestHelper#loadSinkGraph(Graph)} method.
+         */
+        SINK;
 
         private static final List<FeatureRequirement> featuresRequiredByClassic = new ArrayList<FeatureRequirement>() {{
             add(FeatureRequirement.Factory.create(FEATURE_STRING_VALUES, VertexPropertyFeatures.class));
@@ -104,6 +110,10 @@ public @interface LoadGraphWith {
             add(FeatureRequirement.Factory.create(FEATURE_INTEGER_VALUES, VertexPropertyFeatures.class));
         }};
 
+        private static final List<FeatureRequirement> featuresRequiredBySink = new ArrayList<FeatureRequirement>() {{
+            add(FeatureRequirement.Factory.create(FEATURE_STRING_VALUES, VertexPropertyFeatures.class));
+        }};
+
         public String location() {
             switch (this) {
                 case CLASSIC:
@@ -114,6 +124,8 @@ public @interface LoadGraphWith {
                     return RESOURCE_PATH_PREFIX + "tinkerpop-modern.kryo";
                 case GRATEFUL:
                     return RESOURCE_PATH_PREFIX + "grateful-dead.kryo";
+                case SINK:
+                    return RESOURCE_PATH_PREFIX + "tinkerpop-sink.kryo";
             }
 
             throw new RuntimeException("No file for this GraphData type");
@@ -129,6 +141,8 @@ public @interface LoadGraphWith {
                     return featuresRequiredByModern;
                 case GRATEFUL:
                     return featuresRequiredByGrateful;
+                case SINK:
+                    return featuresRequiredBySink;
             }
 
             throw new RuntimeException("No features for this GraphData type");

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/TestHelper.java
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/TestHelper.java b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/TestHelper.java
index 382c39d..833a383 100644
--- a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/TestHelper.java
+++ b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/TestHelper.java
@@ -18,6 +18,7 @@
  */
 package org.apache.tinkerpop.gremlin;
 
+import org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversalSource;
 import org.apache.tinkerpop.gremlin.structure.Direction;
 import org.apache.tinkerpop.gremlin.structure.Edge;
 import org.apache.tinkerpop.gremlin.structure.Graph;
@@ -32,8 +33,6 @@ import java.io.File;
 import java.io.FileOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
-import java.net.MalformedURLException;
-import java.net.URISyntaxException;
 import java.net.URL;
 import java.util.Iterator;
 import java.util.List;

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/branch/RepeatTest.java
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/branch/RepeatTest.java b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/branch/RepeatTest.java
index ae1220f..75bb83f 100644
--- a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/branch/RepeatTest.java
+++ b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/branch/RepeatTest.java
@@ -23,6 +23,7 @@ import org.apache.tinkerpop.gremlin.process.AbstractGremlinProcessTest;
 import org.apache.tinkerpop.gremlin.process.GremlinProcessRunner;
 import org.apache.tinkerpop.gremlin.process.traversal.Path;
 import org.apache.tinkerpop.gremlin.process.traversal.Traversal;
+import org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__;
 import org.apache.tinkerpop.gremlin.process.traversal.step.util.MapHelper;
 import org.apache.tinkerpop.gremlin.structure.T;
 import org.apache.tinkerpop.gremlin.structure.Vertex;
@@ -36,6 +37,7 @@ import java.util.List;
 import java.util.Map;
 
 import static org.apache.tinkerpop.gremlin.LoadGraphWith.GraphData.MODERN;
+import static org.apache.tinkerpop.gremlin.LoadGraphWith.GraphData.SINK;
 import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.both;
 import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.groupCount;
 import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.has;
@@ -43,7 +45,9 @@ import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.in;
 import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.loops;
 import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.out;
 import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.outE;
-import static org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.__.values;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.hamcrest.core.Is.is;
+import static org.hamcrest.collection.IsIterableContainingInOrder.contains;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
@@ -66,6 +70,8 @@ public abstract class RepeatTest extends AbstractGremlinProcessTest {
 
     public abstract Traversal<Vertex, Vertex> get_g_V_repeatXoutX_timesX2X_emit();
 
+    public abstract Traversal<Vertex, Path> get_g_V_hasXloop_name_loopX_repeatXinX_timesX5X_path_by_name();
+
     // WHILE/DO
 
     public abstract Traversal<Vertex, String> get_g_VX1X_timesX2X_repeatXoutX_name(final Object v1Id);
@@ -202,6 +208,16 @@ public abstract class RepeatTest extends AbstractGremlinProcessTest {
     }
 
     @Test
+    @LoadGraphWith(SINK)
+    public void g_V_hasXloop_name_loopX_repeatXinX_timesX5X_path_by_name() {
+        final Traversal<Vertex, Path> traversal = get_g_V_hasXloop_name_loopX_repeatXinX_timesX5X_path_by_name();
+        printTraversalForm(traversal);
+        final Path path = traversal.next();
+        assertThat(path, contains("loop", "loop", "loop", "loop", "loop", "loop"));
+        assertThat(traversal.hasNext(), is(false));
+    }
+
+    @Test
     @LoadGraphWith(MODERN)
     public void g_VX1X_emitXhasXlabel_personXX_repeatXoutX_name() {
         final Traversal<Vertex, String> traversal = get_g_VX1X_emitXhasXlabel_personXX_repeatXoutX_name(convertToVertexId("marko"));
@@ -365,5 +381,10 @@ public abstract class RepeatTest extends AbstractGremlinProcessTest {
         public Traversal<Vertex, Path> get_g_V_hasXname_markoX_repeatXoutE_inV_simplePathX_untilXhasXname_rippleXX_path_byXnameX_byXlabelX() {
             return g.V().has("name", "marko").repeat(outE().inV().simplePath()).until(has("name", "ripple")).path().by("name").by(T.label);
         }
-   }
+
+        @Override
+        public Traversal<Vertex, Path> get_g_V_hasXloop_name_loopX_repeatXinX_timesX5X_path_by_name() {
+            return g.V().has("loops","name","loop").repeat(__.in()).times(5).path().by("name");
+        }
+    }
 }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed.json
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed.json b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed.json
new file mode 100644
index 0000000..f62a717
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed.json
@@ -0,0 +1 @@
+{"@class":"java.util.HashMap","id":["java.lang.Long",0],"label":"loops","inE":{"@class":"java.util.HashMap","self":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",2],"outV":["java.lang.Long",0]}]]},"outE":{"@class":"java.util.HashMap","self":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",2],"inV":["java.lang.Long",0]}]]},"properties":{"@class":"java.util.HashMap","name":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",1],"value":"loop"}]]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0-typed.json
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0-typed.json b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0-typed.json
new file mode 100644
index 0000000..df22167
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0-typed.json
@@ -0,0 +1 @@
+{"id":{"@type":"g:Int64","@value":0},"label":"loops","inE":{"self":[{"id":{"@type":"g:Int64","@value":2},"outV":{"@type":"g:Int64","@value":0}}]},"outE":{"self":[{"id":{"@type":"g:Int64","@value":2},"inV":{"@type":"g:Int64","@value":0}}]},"properties":{"name":[{"id":{"@type":"g:Int64","@value":1},"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
new file mode 100644
index 0000000..39496ba
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
@@ -0,0 +1 @@
+{"id":0,"label":"loops","inE":{"self":[{"id":2,"outV":0}]},"outE":{"self":[{"id":2,"inV":0}]},"properties":{"name":[{"id":1,"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink.json
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink.json b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink.json
new file mode 100644
index 0000000..39496ba
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink.json
@@ -0,0 +1 @@
+{"id":0,"label":"loops","inE":{"self":[{"id":2,"outV":0}]},"outE":{"self":[{"id":2,"inV":0}]},"properties":{"name":[{"id":1,"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/gryo/tinkerpop-sink.kryo
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/gryo/tinkerpop-sink.kryo b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/gryo/tinkerpop-sink.kryo
new file mode 100644
index 0000000..9a26e15
Binary files /dev/null and b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/gryo/tinkerpop-sink.kryo differ

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
----------------------------------------------------------------------
diff --git a/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java b/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
index 9c6a352..0ad3637 100644
--- a/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
+++ b/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
@@ -80,7 +80,8 @@ public class HadoopGraphProvider extends AbstractGraphProvider {
                     "tinkerpop-modern.kryo",
                     "grateful-dead.kryo",
                     "tinkerpop-classic.kryo",
-                    "tinkerpop-crew.kryo");
+                    "tinkerpop-crew.kryo",
+                    "tinkerpop-sink.kryo");
             for (final String fileName : kryoResources) {
                 PATHS.put(fileName, TestHelper.generateTempFileFromResource(GryoResourceAccess.class, fileName, "").getAbsolutePath().replace('\\', '/'));
             }
@@ -89,7 +90,8 @@ public class HadoopGraphProvider extends AbstractGraphProvider {
                     "tinkerpop-modern.json",
                     "grateful-dead.json",
                     "tinkerpop-classic.json",
-                    "tinkerpop-crew.json");
+                    "tinkerpop-crew.json",
+                    "tinkerpop-sink.json");
             for (final String fileName : graphsonResources) {
                 PATHS.put(fileName, TestHelper.generateTempFileFromResource(GraphSONResourceAccess.class, fileName, "").getAbsolutePath().replace('\\', '/'));
             }
@@ -149,7 +151,9 @@ public class HadoopGraphProvider extends AbstractGraphProvider {
             ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-classic." + type));
         } else if (graphData.equals(LoadGraphWith.GraphData.CREW)) {
             ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-crew." + type));
-        } else {
+        } else if (graphData.equals(LoadGraphWith.GraphData.SINK)) {
+            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-sink." + type));
+        }else {
             throw new RuntimeException("Could not load graph with " + graphData);
         }
     }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/tinkergraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/TinkerFactory.java
----------------------------------------------------------------------
diff --git a/tinkergraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/TinkerFactory.java b/tinkergraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/TinkerFactory.java
index 0520ee2..96d26ca 100644
--- a/tinkergraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/TinkerFactory.java
+++ b/tinkergraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/TinkerFactory.java
@@ -20,6 +20,8 @@ package org.apache.tinkerpop.gremlin.tinkergraph.structure;
 
 import org.apache.commons.configuration.BaseConfiguration;
 import org.apache.commons.configuration.Configuration;
+import org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversalSource;
+import org.apache.tinkerpop.gremlin.structure.Graph;
 import org.apache.tinkerpop.gremlin.structure.T;
 import org.apache.tinkerpop.gremlin.structure.Vertex;
 import org.apache.tinkerpop.gremlin.structure.VertexProperty;
@@ -136,6 +138,19 @@ public final class TinkerFactory {
         g.variables().set("comment", "this graph was created to provide examples and test coverage for tinkerpop3 api advances");
     }
 
+    public static TinkerGraph createKitchenSink() {
+        final TinkerGraph g = getTinkerGraphWithNumberManager();
+        generateKitchenSink(g);
+        return g;
+    }
+
+    public static void generateKitchenSink(final TinkerGraph graph) {
+        final GraphTraversalSource g = graph.traversal();
+        g.addV("loops").property(T.id, 1000).property("name", "loop").as("me").
+          addE("self").to("me").
+          iterate();
+    }
+
     private static TinkerGraph getTinkerGraphWithNumberManager() {
         final Configuration conf = getNumberIdManagerConfiguration();
         return TinkerGraph.open(conf);

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/TinkerGraphProvider.java
----------------------------------------------------------------------
diff --git a/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/TinkerGraphProvider.java b/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/TinkerGraphProvider.java
index d6dd562..7f0e6f3 100644
--- a/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/TinkerGraphProvider.java
+++ b/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/TinkerGraphProvider.java
@@ -200,6 +200,8 @@ public class TinkerGraphProvider extends AbstractGraphProvider {
             return TinkerGraph.DefaultIdManager.INTEGER;
         else if (loadGraphWith.equals(LoadGraphWith.GraphData.GRATEFUL))
             return TinkerGraph.DefaultIdManager.INTEGER;
+        else if (loadGraphWith.equals(LoadGraphWith.GraphData.SINK))
+            return TinkerGraph.DefaultIdManager.INTEGER;
         else
             throw new IllegalStateException(String.format("Need to define a new %s for %s", TinkerGraph.IdManager.class.getName(), loadGraphWith.name()));
     }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/5f67d9c8/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
----------------------------------------------------------------------
diff --git a/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java b/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
index d07105b..5aea149 100644
--- a/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
+++ b/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
@@ -95,6 +95,16 @@ public class IoDataGenerationTest {
     }
 
     /**
+     * No assertions. Just write out the graph for convenience
+     */
+    @Test
+    public void shouldWriteKitchenSinkAsGryo() throws IOException {
+        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink.kryo");
+        GryoWriter.build().create().writeGraph(os, TinkerFactory.createKitchenSink());
+        os.close();
+    }
+
+    /**
      * No assertions.  Just write out the graph for convenience.
      */
     @Test
@@ -145,6 +155,16 @@ public class IoDataGenerationTest {
     }
 
     /**
+     * No assertions. Just write out the graph for convenience
+     */
+    @Test
+    public void shouldWriteKitchenSinkAsGraphSONNoTypes() throws IOException {
+        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink.json");
+        GraphSONWriter.build().create().writeGraph(os, TinkerFactory.createKitchenSink());
+        os.close();
+    }
+
+    /**
      * No assertions.  Just write out the graph for convenience.
      */
     @Test
@@ -198,6 +218,17 @@ public class IoDataGenerationTest {
     }
 
     /**
+     * No assertions. Just write out the graph for convenience
+     */
+    @Test
+    public void shouldWriteKitchenSinkAsGraphSONWithTypes() throws IOException {
+        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-typed.json");
+        GraphSONWriter.build().mapper(GraphSONMapper.build().embedTypes(true).create())
+                .create().writeGraph(os, TinkerFactory.createKitchenSink());
+        os.close();
+    }
+
+    /**
      * No assertions.  Just write out the graph for convenience.
      */
     @Test
@@ -231,6 +262,17 @@ public class IoDataGenerationTest {
     }
 
     /**
+     * No assertions. Just write out the graph for convenience
+     */
+    @Test
+    public void shouldWriteKitchenSinkAsGraphSONV2d0NoTypes() throws IOException {
+        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-v2d0.json");
+        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V2_0).typeInfo(TypeInfo.NO_TYPES).create()).create()
+                .writeGraph(os, TinkerFactory.createKitchenSink());
+        os.close();
+    }
+
+    /**
      * No assertions.  Just write out the graph for convenience.
      */
     @Test
@@ -285,6 +327,17 @@ public class IoDataGenerationTest {
         os.close();
     }
 
+    /**
+     * No assertions. Just write out the graph for convenience
+     */
+    @Test
+    public void shouldWriteKitchenSinkAsGraphSONV2d0WithTypes() throws IOException {
+        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-v2d0-typed.json");
+        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V2_0).create()).create()
+                .writeGraph(os, TinkerFactory.createKitchenSink());
+        os.close();
+    }
+
     @Test
     public void shouldWriteSampleForGremlinServer() throws IOException {
         final Graph g = TinkerGraph.open();


[2/6] tinkerpop git commit: Merge branch 'TINKERPOP-1877' into TINKERPOP-1877-master

Posted by sp...@apache.org.
Merge branch 'TINKERPOP-1877' into TINKERPOP-1877-master

Conflicts:
	gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/branch/GroovyRepeatTest.groovy
	gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
	gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
	hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
	tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/eb6bf217
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/eb6bf217
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/eb6bf217

Branch: refs/heads/master
Commit: eb6bf217c90fa9da40f1a155f024991cadff3deb
Parents: b86b183 5f67d9c
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Thu Feb 1 07:48:20 2018 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Thu Feb 1 07:48:20 2018 -0500

----------------------------------------------------------------------
 CHANGELOG.asciidoc                              |   1 +
 .../upgrade/release-3.2.x-incubating.asciidoc   |  24 ++++++-
 .../gremlin/util/TinkerGraphProvider.java       |   2 +
 gremlin-server/scripts/generate-all.groovy      |   6 +-
 .../driver/remote/RemoteGraphProvider.java      |   7 +-
 .../remote/gremlin-server-integration.yaml      |   3 +-
 .../apache/tinkerpop/gremlin/LoadGraphWith.java |  16 ++++-
 .../apache/tinkerpop/gremlin/TestHelper.java    |   3 +-
 .../traversal/step/branch/RepeatTest.java       |  25 +++++++-
 .../io/graphson/tinkerpop-sink-typed-v1d0.json  |   1 +
 .../io/graphson/tinkerpop-sink-typed-v2d0.json  |   1 +
 .../io/graphson/tinkerpop-sink-v1d0.json        |   1 +
 .../io/graphson/tinkerpop-sink-v2d0.json        |   1 +
 .../io/graphson/tinkerpop-sink-v3d0.json        |   1 +
 .../structure/io/gryo/tinkerpop-sink-v3d0.kryo  | Bin 0 -> 79 bytes
 .../gremlin/hadoop/HadoopGraphProvider.java     |   8 ++-
 .../tinkergraph/structure/TinkerFactory.java    |  15 +++++
 .../tinkergraph/TinkerGraphProvider.java        |   2 +
 .../structure/IoDataGenerationTest.java         |  64 +++++++++++++++++++
 19 files changed, 166 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/CHANGELOG.asciidoc
----------------------------------------------------------------------
diff --cc CHANGELOG.asciidoc
index 11b0816,c562ccd..1ba3aa8
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@@ -272,9 -23,9 +272,10 @@@ image::https://raw.githubusercontent.co
  [[release-3-2-8]]
  === TinkerPop 3.2.8 (Release Date: NOT OFFICIALLY RELEASED YET)
  
+ * Added the "Kitchen Sink" test data set.
  * Fixed a bug in `NumberHelper` that led to wrong min/max results if numbers exceeded the Integer limits.
  * Delayed setting of the request identifier until `RequestMessage` construction by the builder.
 +* `ReferenceElement` avoids `UnsupportedOperationException` handling in construction thus improving performance.
  * Removed hardcoded expectation in metrics serialization test suite as different providers may have different outputs.
  * Added `IndexedTraverserSet` which indexes on the value of a `Traverser` thus improving performance when used.
  * Utilized `IndexedTraverserSet` in `TraversalVertexProgram` to avoid extra iteration when doing `Vertex` lookups.

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/docs/src/upgrade/release-3.2.x-incubating.asciidoc
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-groovy/src/test/java/org/apache/tinkerpop/gremlin/util/TinkerGraphProvider.java
----------------------------------------------------------------------
diff --cc gremlin-groovy/src/test/java/org/apache/tinkerpop/gremlin/util/TinkerGraphProvider.java
index c71a31b,0000000..7a87414
mode 100644,000000..100644
--- a/gremlin-groovy/src/test/java/org/apache/tinkerpop/gremlin/util/TinkerGraphProvider.java
+++ b/gremlin-groovy/src/test/java/org/apache/tinkerpop/gremlin/util/TinkerGraphProvider.java
@@@ -1,206 -1,0 +1,208 @@@
 +/*
 + * Licensed to the Apache Software Foundation (ASF) under one
 + * or more contributor license agreements.  See the NOTICE file
 + * distributed with this work for additional information
 + * regarding copyright ownership.  The ASF licenses this file
 + * to you under the Apache License, Version 2.0 (the
 + * "License"); you may not use this file except in compliance
 + * with the License.  You may obtain a copy of the License at
 + *
 + * http://www.apache.org/licenses/LICENSE-2.0
 + *
 + * Unless required by applicable law or agreed to in writing,
 + * software distributed under the License is distributed on an
 + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 + * KIND, either express or implied.  See the License for the
 + * specific language governing permissions and limitations
 + * under the License.
 + */
 +package org.apache.tinkerpop.gremlin.util;
 +
 +import org.apache.commons.configuration.Configuration;
 +import org.apache.tinkerpop.gremlin.AbstractGraphProvider;
 +import org.apache.tinkerpop.gremlin.LoadGraphWith;
 +import org.apache.tinkerpop.gremlin.TestHelper;
 +import org.apache.tinkerpop.gremlin.structure.Graph;
 +import org.apache.tinkerpop.gremlin.structure.GraphTest;
 +import org.apache.tinkerpop.gremlin.structure.VertexProperty;
 +import org.apache.tinkerpop.gremlin.structure.io.IoEdgeTest;
 +import org.apache.tinkerpop.gremlin.structure.io.IoVertexTest;
 +import org.apache.tinkerpop.gremlin.structure.util.detached.DetachedGraphTest;
 +import org.apache.tinkerpop.gremlin.structure.util.star.StarGraphTest;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerEdge;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerElement;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerGraph;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerGraphVariables;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerProperty;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerVertex;
 +import org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerVertexProperty;
 +
 +import java.io.File;
 +import java.util.HashMap;
 +import java.util.HashSet;
 +import java.util.Map;
 +import java.util.Set;
 +
 +/**
 + * @author Stephen Mallette (http://stephen.genoprime.com)
 + */
 +public class TinkerGraphProvider extends AbstractGraphProvider {
 +
 +    private static final Set<Class> IMPLEMENTATION = new HashSet<Class>() {{
 +        add(TinkerEdge.class);
 +        add(TinkerElement.class);
 +        add(TinkerGraph.class);
 +        add(TinkerGraphVariables.class);
 +        add(TinkerProperty.class);
 +        add(TinkerVertex.class);
 +        add(TinkerVertexProperty.class);
 +    }};
 +
 +    @Override
 +    public Map<String, Object> getBaseConfiguration(final String graphName, final Class<?> test, final String testMethodName,
 +                                                    final LoadGraphWith.GraphData loadGraphWith) {
 +        final TinkerGraph.DefaultIdManager idManager = selectIdMakerFromGraphData(loadGraphWith);
 +        final String idMaker = (idManager.equals(TinkerGraph.DefaultIdManager.ANY) ? selectIdMakerFromTest(test, testMethodName) : idManager).name();
 +        return new HashMap<String, Object>() {{
 +            put(Graph.GRAPH, TinkerGraph.class.getName());
 +            put(TinkerGraph.GREMLIN_TINKERGRAPH_VERTEX_ID_MANAGER, idMaker);
 +            put(TinkerGraph.GREMLIN_TINKERGRAPH_EDGE_ID_MANAGER, idMaker);
 +            put(TinkerGraph.GREMLIN_TINKERGRAPH_VERTEX_PROPERTY_ID_MANAGER, idMaker);
 +            if (requiresListCardinalityAsDefault(loadGraphWith, test, testMethodName))
 +                put(TinkerGraph.GREMLIN_TINKERGRAPH_DEFAULT_VERTEX_PROPERTY_CARDINALITY, VertexProperty.Cardinality.list.name());
 +            if (requiresPersistence(test, testMethodName)) {
 +                put(TinkerGraph.GREMLIN_TINKERGRAPH_GRAPH_FORMAT, "gryo");
 +                final File tempDir = TestHelper.makeTestDataPath(test, "temp");
 +                put(TinkerGraph.GREMLIN_TINKERGRAPH_GRAPH_LOCATION,
 +                        tempDir.getAbsolutePath() + File.separator + testMethodName + ".kryo");
 +            }
 +        }};
 +    }
 +
 +    @Override
 +    public void clear(final Graph graph, final Configuration configuration) throws Exception {
 +        if (graph != null)
 +            graph.close();
 +
 +        // in the even the graph is persisted we need to clean up
 +        final String graphLocation = configuration.getString(TinkerGraph.GREMLIN_TINKERGRAPH_GRAPH_LOCATION, null);
 +        if (graphLocation != null) {
 +            final File f = new File(graphLocation);
 +            f.delete();
 +        }
 +    }
 +
 +    @Override
 +    public Set<Class> getImplementations() {
 +        return IMPLEMENTATION;
 +    }
 +
 +    /**
 +     * Determines if a test requires TinkerGraph persistence to be configured with graph location and format.
 +     */
 +    protected static boolean requiresPersistence(final Class<?> test, final String testMethodName) {
 +        return test == GraphTest.class && testMethodName.equals("shouldPersistDataOnClose");
 +    }
 +
 +    /**
 +     * Determines if a test requires a different cardinality as the default or not.
 +     */
 +    protected static boolean requiresListCardinalityAsDefault(final LoadGraphWith.GraphData loadGraphWith,
 +                                                            final Class<?> test, final String testMethodName) {
 +        return loadGraphWith == LoadGraphWith.GraphData.CREW
 +                || (test == StarGraphTest.class && testMethodName.equals("shouldAttachWithCreateMethod"))
 +                || (test == DetachedGraphTest.class && testMethodName.equals("testAttachableCreateMethod"));
 +    }
 +
 +    /**
 +     * Some tests require special configuration for TinkerGraph to properly configure the id manager.
 +     */
 +    protected TinkerGraph.DefaultIdManager selectIdMakerFromTest(final Class<?> test, final String testMethodName) {
 +        if (test.equals(GraphTest.class)) {
 +            final Set<String> testsThatNeedLongIdManager = new HashSet<String>(){{
 +                add("shouldIterateVerticesWithNumericIdSupportUsingDoubleRepresentation");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingDoubleRepresentations");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingIntegerRepresentation");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingIntegerRepresentations");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingFloatRepresentation");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingFloatRepresentations");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingStringRepresentation");
 +                add("shouldIterateVerticesWithNumericIdSupportUsingStringRepresentations");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingDoubleRepresentation");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingDoubleRepresentations");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingIntegerRepresentation");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingIntegerRepresentations");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingFloatRepresentation");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingFloatRepresentations");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingStringRepresentation");
 +                add("shouldIterateEdgesWithNumericIdSupportUsingStringRepresentations");
 +            }};
 +
 +            final Set<String> testsThatNeedUuidIdManager = new HashSet<String>(){{
 +                add("shouldIterateVerticesWithUuidIdSupportUsingStringRepresentation");
 +                add("shouldIterateVerticesWithUuidIdSupportUsingStringRepresentations");
 +                add("shouldIterateEdgesWithUuidIdSupportUsingStringRepresentation");
 +                add("shouldIterateEdgesWithUuidIdSupportUsingStringRepresentations");
 +            }};
 +
 +            if (testsThatNeedLongIdManager.contains(testMethodName))
 +                return TinkerGraph.DefaultIdManager.LONG;
 +            else if (testsThatNeedUuidIdManager.contains(testMethodName))
 +                return TinkerGraph.DefaultIdManager.UUID;
 +        }  else if (test.equals(IoEdgeTest.class)) {
 +            final Set<String> testsThatNeedLongIdManager = new HashSet<String>(){{
 +                add("shouldReadWriteEdge[graphson-v1]");
 +                add("shouldReadWriteDetachedEdgeAsReference[graphson-v1]");
 +                add("shouldReadWriteDetachedEdge[graphson-v1]");
 +                add("shouldReadWriteEdge[graphson-v2]");
 +                add("shouldReadWriteDetachedEdgeAsReference[graphson-v2]");
 +                add("shouldReadWriteDetachedEdge[graphson-v2]");
 +            }};
 +
 +            if (testsThatNeedLongIdManager.contains(testMethodName))
 +                return TinkerGraph.DefaultIdManager.LONG;
 +        } else if (test.equals(IoVertexTest.class)) {
 +            final Set<String> testsThatNeedLongIdManager = new HashSet<String>(){{
 +                add("shouldReadWriteVertexWithBOTHEdges[graphson-v1]");
 +                add("shouldReadWriteVertexWithINEdges[graphson-v1]");
 +                add("shouldReadWriteVertexWithOUTEdges[graphson-v1]");
 +                add("shouldReadWriteVertexNoEdges[graphson-v1]");
 +                add("shouldReadWriteDetachedVertexNoEdges[graphson-v1]");
 +                add("shouldReadWriteDetachedVertexAsReferenceNoEdges[graphson-v1]");
 +                add("shouldReadWriteVertexMultiPropsNoEdges[graphson-v1]");
 +                add("shouldReadWriteVertexWithBOTHEdges[graphson-v2]");
 +                add("shouldReadWriteVertexWithINEdges[graphson-v2]");
 +                add("shouldReadWriteVertexWithOUTEdges[graphson-v2]");
 +                add("shouldReadWriteVertexNoEdges[graphson-v2]");
 +                add("shouldReadWriteDetachedVertexNoEdges[graphson-v2]");
 +                add("shouldReadWriteDetachedVertexAsReferenceNoEdges[graphson-v2]");
 +                add("shouldReadWriteVertexMultiPropsNoEdges[graphson-v2]");
 +            }};
 +
 +            if (testsThatNeedLongIdManager.contains(testMethodName))
 +                return TinkerGraph.DefaultIdManager.LONG;
 +        }
 +
 +        return TinkerGraph.DefaultIdManager.ANY;
 +    }
 +
 +    /**
 +     * Test that load with specific graph data can be configured with a specific id manager as the data type to
 +     * be used in the test for that graph is known.
 +     */
 +    protected TinkerGraph.DefaultIdManager selectIdMakerFromGraphData(final LoadGraphWith.GraphData loadGraphWith) {
 +        if (null == loadGraphWith) return TinkerGraph.DefaultIdManager.ANY;
 +        if (loadGraphWith.equals(LoadGraphWith.GraphData.CLASSIC))
 +            return TinkerGraph.DefaultIdManager.INTEGER;
 +        else if (loadGraphWith.equals(LoadGraphWith.GraphData.MODERN))
 +            return TinkerGraph.DefaultIdManager.INTEGER;
 +        else if (loadGraphWith.equals(LoadGraphWith.GraphData.CREW))
 +            return TinkerGraph.DefaultIdManager.INTEGER;
 +        else if (loadGraphWith.equals(LoadGraphWith.GraphData.GRATEFUL))
 +            return TinkerGraph.DefaultIdManager.INTEGER;
++        else if (loadGraphWith.equals(LoadGraphWith.GraphData.SINK))
++            return TinkerGraph.DefaultIdManager.INTEGER;
 +        else
 +            throw new IllegalStateException(String.format("Need to define a new %s for %s", TinkerGraph.IdManager.class.getName(), loadGraphWith.name()));
 +    }
 +}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
----------------------------------------------------------------------
diff --cc gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
index cf95f0a,28ea1ac..686ea9c
--- a/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
+++ b/gremlin-server/src/test/resources/org/apache/tinkerpop/gremlin/driver/remote/gremlin-server-integration.yaml
@@@ -23,21 -23,22 +23,22 @@@ graphs: 
    classic: conf/tinkergraph-empty.properties,
    modern: conf/tinkergraph-empty.properties,
    crew: conf/tinkergraph-empty.properties,
-   grateful: conf/tinkergraph-empty.properties}
+   grateful: conf/tinkergraph-empty.properties,
+   sink: conf/tinkergraph-empty.properties}
 -plugins:
 -  - tinkerpop.tinkergraph
  scriptEngines: {
    gremlin-groovy: {
 -    imports: [java.lang.Math],
 -    staticImports: [java.lang.Math.PI],
 -    scripts: [scripts/generate-all.groovy]}}
 +    plugins: { org.apache.tinkerpop.gremlin.server.jsr223.GremlinServerGremlinPlugin: {},
 +               org.apache.tinkerpop.gremlin.tinkergraph.jsr223.TinkerGraphGremlinPlugin: {},
 +               org.apache.tinkerpop.gremlin.jsr223.ImportGremlinPlugin: {classImports: [java.lang.Math], methodImports: [java.lang.Math#*]},
 +               org.apache.tinkerpop.gremlin.jsr223.ScriptFileGremlinPlugin: {files: [scripts/generate-all.groovy]}}}}
  serializers:
    - { className: org.apache.tinkerpop.gremlin.driver.ser.GryoMessageSerializerV1d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV1d0], custom: [groovy.json.JsonBuilder;org.apache.tinkerpop.gremlin.driver.ser.JsonBuilderGryoSerializer]}}
 +  - { className: org.apache.tinkerpop.gremlin.driver.ser.GryoMessageSerializerV3d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV3d0], custom: [groovy.json.JsonBuilder;org.apache.tinkerpop.gremlin.driver.ser.JsonBuilderGryoSerializer]}}
    - { className: org.apache.tinkerpop.gremlin.driver.ser.GryoLiteMessageSerializerV1d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV1d0], custom: [groovy.json.JsonBuilder;org.apache.tinkerpop.gremlin.driver.ser.JsonBuilderGryoSerializer]}}
 -  - { className: org.apache.tinkerpop.gremlin.driver.ser.GryoMessageSerializerV1d0, config: { serializeResultToString: true}}
 +  - { className: org.apache.tinkerpop.gremlin.driver.ser.GryoMessageSerializerV3d0, config: { serializeResultToString: true}}
    - { className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerGremlinV1d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV1d0] }}
    - { className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerGremlinV2d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV2d0] }}
 -  - { className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerV1d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV1d0] }}
 +  - { className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerV3d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV3d0] }}
  processors:
    - { className: org.apache.tinkerpop.gremlin.server.op.session.SessionOpProcessor, config: { sessionTimeout: 28800000 }}
  metrics: {

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
index 737d975,9fc2056..212305c
--- a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
+++ b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/LoadGraphWith.java
@@@ -107,13 -117,15 +117,15 @@@ public @interface LoadGraphWith 
          public String location() {
              switch (this) {
                  case CLASSIC:
 -                    return RESOURCE_PATH_PREFIX + "tinkerpop-classic.kryo";
 +                    return RESOURCE_PATH_PREFIX + "tinkerpop-classic-v3d0.kryo";
                  case CREW:
 -                    return RESOURCE_PATH_PREFIX + "tinkerpop-crew.kryo";
 +                    return RESOURCE_PATH_PREFIX + "tinkerpop-crew-v3d0.kryo";
                  case MODERN:
 -                    return RESOURCE_PATH_PREFIX + "tinkerpop-modern.kryo";
 +                    return RESOURCE_PATH_PREFIX + "tinkerpop-modern-v3d0.kryo";
                  case GRATEFUL:
 -                    return RESOURCE_PATH_PREFIX + "grateful-dead.kryo";
 +                    return RESOURCE_PATH_PREFIX + "grateful-dead-v3d0.kryo";
+                 case SINK:
 -                    return RESOURCE_PATH_PREFIX + "tinkerpop-sink.kryo";
++                    return RESOURCE_PATH_PREFIX + "tinkerpop-sink-v3d0.kryo";
              }
  
              throw new RuntimeException("No file for this GraphData type");

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed-v1d0.json
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed-v1d0.json
index 0000000,0000000..c37b54a
new file mode 100644
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed-v1d0.json
@@@ -1,0 -1,0 +1,1 @@@
++{"@class":"java.util.HashMap","id":1000,"label":"loops","inE":{"@class":"java.util.HashMap","self":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":1,"outV":1000}]]},"outE":{"@class":"java.util.HashMap","self":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":1,"inV":1000}]]},"properties":{"@class":"java.util.HashMap","name":["java.util.ArrayList",[{"@class":"java.util.HashMap","id":["java.lang.Long",0],"value":"loop"}]]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed-v2d0.json
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed-v2d0.json
index 0000000,0000000..c953075
new file mode 100644
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-typed-v2d0.json
@@@ -1,0 -1,0 +1,1 @@@
++{"id":{"@type":"g:Int32","@value":1000},"label":"loops","inE":{"self":[{"id":{"@type":"g:Int32","@value":1},"outV":{"@type":"g:Int32","@value":1000}}]},"outE":{"self":[{"id":{"@type":"g:Int32","@value":1},"inV":{"@type":"g:Int32","@value":1000}}]},"properties":{"name":[{"id":{"@type":"g:Int64","@value":0},"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v1d0.json
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v1d0.json
index 0000000,0000000..a69b24f
new file mode 100644
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v1d0.json
@@@ -1,0 -1,0 +1,1 @@@
++{"id":1000,"label":"loops","inE":{"self":[{"id":1,"outV":1000}]},"outE":{"self":[{"id":1,"inV":1000}]},"properties":{"name":[{"id":0,"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
index 0000000,39496ba..a69b24f
mode 000000,100644..100644
--- a/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v2d0.json
@@@ -1,0 -1,1 +1,1 @@@
 -{"id":0,"label":"loops","inE":{"self":[{"id":2,"outV":0}]},"outE":{"self":[{"id":2,"inV":0}]},"properties":{"name":[{"id":1,"value":"loop"}]}}
++{"id":1000,"label":"loops","inE":{"self":[{"id":1,"outV":1000}]},"outE":{"self":[{"id":1,"inV":1000}]},"properties":{"name":[{"id":0,"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v3d0.json
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v3d0.json
index 0000000,0000000..c953075
new file mode 100644
--- /dev/null
+++ b/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/graphson/tinkerpop-sink-v3d0.json
@@@ -1,0 -1,0 +1,1 @@@
++{"id":{"@type":"g:Int32","@value":1000},"label":"loops","inE":{"self":[{"id":{"@type":"g:Int32","@value":1},"outV":{"@type":"g:Int32","@value":1000}}]},"outE":{"self":[{"id":{"@type":"g:Int32","@value":1},"inV":{"@type":"g:Int32","@value":1000}}]},"properties":{"name":[{"id":{"@type":"g:Int64","@value":0},"value":"loop"}]}}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/gryo/tinkerpop-sink-v3d0.kryo
----------------------------------------------------------------------
diff --cc gremlin-test/src/main/resources/org/apache/tinkerpop/gremlin/structure/io/gryo/tinkerpop-sink-v3d0.kryo
index 0000000,0000000..ffb944f
new file mode 100644
Binary files differ

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
----------------------------------------------------------------------
diff --cc hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
index 4410793,0ad3637..79a039a
--- a/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
+++ b/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
@@@ -76,23 -77,21 +76,25 @@@ public class HadoopGraphProvider extend
      static {
          try {
              final List<String> kryoResources = Arrays.asList(
 -                    "tinkerpop-modern.kryo",
 -                    "grateful-dead.kryo",
 -                    "tinkerpop-classic.kryo",
 -                    "tinkerpop-crew.kryo",
 -                    "tinkerpop-sink.kryo");
 +                    "tinkerpop-modern-v3d0.kryo",
 +                    "grateful-dead-v3d0.kryo",
 +                    "tinkerpop-classic-v3d0.kryo",
-                     "tinkerpop-crew-v3d0.kryo");
++                    "tinkerpop-crew-v3d0.kryo",
++                    "tinkerpop-sink-v3d0.kryo");
              for (final String fileName : kryoResources) {
                  PATHS.put(fileName, TestHelper.generateTempFileFromResource(GryoResourceAccess.class, fileName, "").getAbsolutePath().replace('\\', '/'));
              }
  
              final List<String> graphsonResources = Arrays.asList(
 -                    "tinkerpop-modern.json",
 -                    "grateful-dead.json",
 -                    "tinkerpop-classic.json",
 -                    "tinkerpop-crew.json",
 -                    "tinkerpop-sink.json");
 +                    "tinkerpop-modern-typed-v2d0.json",
 +                    "tinkerpop-modern-v3d0.json",
 +                    "grateful-dead-typed-v2d0.json",
 +                    "grateful-dead-v3d0.json",
 +                    "tinkerpop-classic-typed-v2d0.json",
 +                    "tinkerpop-classic-v3d0.json",
 +                    "tinkerpop-crew-typed-v2d0.json",
-                     "tinkerpop-crew-v3d0.json");
++                    "tinkerpop-crew-v3d0.json",
++                    "tinkerpop-sink-v3d0.json");
              for (final String fileName : graphsonResources) {
                  PATHS.put(fileName, TestHelper.generateTempFileFromResource(GraphSONResourceAccess.class, fileName, "").getAbsolutePath().replace('\\', '/'));
              }
@@@ -141,17 -141,19 +143,19 @@@
      }
  
      public void loadGraphDataViaHadoopConfig(final Graph g, final LoadGraphWith.GraphData graphData) {
 -        final String type = this.graphSONInput ? "json" : "kryo";
 +        final String type = this.graphSONInput ? "-v3d0.json" : "-v3d0.kryo";
  
          if (graphData.equals(LoadGraphWith.GraphData.GRATEFUL)) {
 -            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("grateful-dead." + type));
 +            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("grateful-dead" + type));
          } else if (graphData.equals(LoadGraphWith.GraphData.MODERN)) {
 -            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-modern." + type));
 +            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-modern" + type));
          } else if (graphData.equals(LoadGraphWith.GraphData.CLASSIC)) {
 -            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-classic." + type));
 +            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-classic" + type));
          } else if (graphData.equals(LoadGraphWith.GraphData.CREW)) {
 -            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-crew." + type));
 +            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-crew" + type));
+         } else if (graphData.equals(LoadGraphWith.GraphData.SINK)) {
+             ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-sink." + type));
 -        }else {
 +        } else {
              throw new RuntimeException("Could not load graph with " + graphData);
          }
      }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eb6bf217/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
----------------------------------------------------------------------
diff --cc tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
index 313716f,5aea149..1fb2ee6
--- a/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
+++ b/tinkergraph-gremlin/src/test/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/IoDataGenerationTest.java
@@@ -97,62 -95,12 +97,72 @@@ public class IoDataGenerationTest 
      }
  
      /**
 -     * No assertions. Just write out the graph for convenience
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteClassicGraphAsGryoV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-classic-v3d0.kryo");
 +        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createClassic());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteModernGraphAsGryoV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-modern-v3d0.kryo");
 +        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createModern());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteCrewGraphAsGryoV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-crew-v3d0.kryo");
 +        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createTheCrew());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
++    public void shouldWriteSinkGraphAsGryoV3d0() throws IOException {
++        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-v3d0.kryo");
++        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createKitchenSink());
++        os.close();
++    }
++
++    /**
++     * No assertions.  Just write out the graph for convenience.
++     */
++    @Test
 +    public void shouldWriteDEFAULTClassicGraphAsGryoV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-classic.kryo");
 +        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createClassic());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
       */
      @Test
 -    public void shouldWriteKitchenSinkAsGryo() throws IOException {
 -        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink.kryo");
 -        GryoWriter.build().create().writeGraph(os, TinkerFactory.createKitchenSink());
 +    public void shouldWriteDEFAULTModernGraphAsGryoV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-modern.kryo");
 +        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createModern());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteDEFAULTCrewGraphAsGryoV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-crew.kryo");
 +        GryoWriter.build().mapper(GryoMapper.build().version(GryoVersion.V3_0).create()).create().writeGraph(os, TinkerFactory.createTheCrew());
          os.close();
      }
  
@@@ -207,6 -155,16 +217,16 @@@
      }
  
      /**
+      * No assertions. Just write out the graph for convenience
+      */
+     @Test
+     public void shouldWriteKitchenSinkAsGraphSONNoTypes() throws IOException {
 -        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink.json");
 -        GraphSONWriter.build().create().writeGraph(os, TinkerFactory.createKitchenSink());
++        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-v1d0.json");
++        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V1_0).typeInfo(TypeInfo.NO_TYPES).create()).create().writeGraph(os, TinkerFactory.createKitchenSink());
+         os.close();
+     }
+ 
+     /**
       * No assertions.  Just write out the graph for convenience.
       */
      @Test
@@@ -260,6 -218,17 +280,17 @@@
      }
  
      /**
+      * No assertions. Just write out the graph for convenience
+      */
+     @Test
+     public void shouldWriteKitchenSinkAsGraphSONWithTypes() throws IOException {
 -        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-typed.json");
 -        GraphSONWriter.build().mapper(GraphSONMapper.build().embedTypes(true).create())
++        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-typed-v1d0.json");
++        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V1_0).typeInfo(TypeInfo.PARTIAL_TYPES).create())
+                 .create().writeGraph(os, TinkerFactory.createKitchenSink());
+         os.close();
+     }
+ 
+     /**
       * No assertions.  Just write out the graph for convenience.
       */
      @Test
@@@ -348,93 -328,16 +390,115 @@@
      }
  
      /**
+      * No assertions. Just write out the graph for convenience
+      */
+     @Test
+     public void shouldWriteKitchenSinkAsGraphSONV2d0WithTypes() throws IOException {
 -        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-v2d0-typed.json");
 -        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V2_0).create()).create()
++        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-typed-v2d0.json");
++        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V2_0).typeInfo(TypeInfo.PARTIAL_TYPES).create()).create()
++                .writeGraph(os, TinkerFactory.createKitchenSink());
++        os.close();
++    }
++
++    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteClassicGraphAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-classic-v3d0.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
 +                .writeGraph(os, TinkerFactory.createClassic());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteModernGraphAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-modern-v3d0.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
 +                .writeGraph(os, TinkerFactory.createModern());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteCrewGraphAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-crew-v3d0.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
 +                .writeGraph(os, TinkerFactory.createTheCrew());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
++    public void shouldWriteSinkGraphAsGraphSONV3d0() throws IOException {
++        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-sink-v3d0.json");
++        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
+                 .writeGraph(os, TinkerFactory.createKitchenSink());
+         os.close();
+     }
+ 
++    /**
++     * No assertions.  Just write out the graph for convenience.
++     */
++    @Test
 +    public void shouldWriteDEFAULTClassicGraphAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-classic.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
 +                .writeGraph(os, TinkerFactory.createClassic());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteDEFAULTModernGraphAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-modern.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
 +                .writeGraph(os, TinkerFactory.createModern());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteDEFAULTCrewGraphAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-crew.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).create()).create()
 +                .writeGraph(os, TinkerFactory.createTheCrew());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteClassicGraphNormalizedAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-classic-normalized-v3d0.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).normalize(true).create()).create()
 +                .writeGraph(os, TinkerFactory.createClassic());
 +        os.close();
 +    }
 +
 +    /**
 +     * No assertions.  Just write out the graph for convenience.
 +     */
 +    @Test
 +    public void shouldWriteModernGraphNormalizedAsGraphSONV3d0() throws IOException {
 +        final OutputStream os = new FileOutputStream(tempPath + "tinkerpop-modern-normalized-v3d0.json");
 +        GraphSONWriter.build().mapper(GraphSONMapper.build().version(GraphSONVersion.V3_0).normalize(true).create()).create()
 +                .writeGraph(os, TinkerFactory.createModern());
 +        os.close();
 +    }
 +
      @Test
      public void shouldWriteSampleForGremlinServer() throws IOException {
          final Graph g = TinkerGraph.open();


[4/6] tinkerpop git commit: Merge branch 'TINKERPOP-1877' into tp32

Posted by sp...@apache.org.
Merge branch 'TINKERPOP-1877' into tp32


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/4e284c02
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/4e284c02
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/4e284c02

Branch: refs/heads/master
Commit: 4e284c026c5753e32b5d3c662eee5d78d0f4c1b4
Parents: 9a7a998 5f67d9c
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Thu Feb 8 11:02:16 2018 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Thu Feb 8 11:02:16 2018 -0500

----------------------------------------------------------------------
 CHANGELOG.asciidoc                              |   1 +
 data/tinkerpop-sink-typed.json                  |   1 +
 data/tinkerpop-sink-v2d0-typed.json             |   1 +
 data/tinkerpop-sink-v2d0.json                   |   1 +
 data/tinkerpop-sink.json                        |   1 +
 data/tinkerpop-sink.kryo                        | Bin 0 -> 76 bytes
 .../upgrade/release-3.2.x-incubating.asciidoc   |  24 ++++++++-
 .../step/branch/GroovyRepeatTest.groovy         |   5 ++
 gremlin-server/scripts/generate-all.groovy      |   6 ++-
 .../driver/remote/RemoteGraphProvider.java      |   7 +--
 .../remote/gremlin-server-integration.yaml      |   3 +-
 .../apache/tinkerpop/gremlin/LoadGraphWith.java |  16 +++++-
 .../apache/tinkerpop/gremlin/TestHelper.java    |   3 +-
 .../traversal/step/branch/RepeatTest.java       |  25 ++++++++-
 .../io/graphson/tinkerpop-sink-typed.json       |   1 +
 .../io/graphson/tinkerpop-sink-v2d0-typed.json  |   1 +
 .../io/graphson/tinkerpop-sink-v2d0.json        |   1 +
 .../structure/io/graphson/tinkerpop-sink.json   |   1 +
 .../structure/io/gryo/tinkerpop-sink.kryo       | Bin 0 -> 76 bytes
 .../gremlin/hadoop/HadoopGraphProvider.java     |  10 ++--
 .../tinkergraph/structure/TinkerFactory.java    |  15 ++++++
 .../tinkergraph/TinkerGraphProvider.java        |   2 +
 .../structure/IoDataGenerationTest.java         |  53 +++++++++++++++++++
 23 files changed, 162 insertions(+), 16 deletions(-)
----------------------------------------------------------------------



[6/6] tinkerpop git commit: Merge branch 'tp32'

Posted by sp...@apache.org.
Merge branch 'tp32'


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/304a7ae3
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/304a7ae3
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/304a7ae3

Branch: refs/heads/master
Commit: 304a7ae3ff9098d575e7e871d45e98ec2310b37c
Parents: 12479c6 4e284c0
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Thu Feb 8 11:02:37 2018 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Thu Feb 8 11:02:37 2018 -0500

----------------------------------------------------------------------

----------------------------------------------------------------------



[5/6] tinkerpop git commit: Merge branch 'TINKERPOP-1877-master'

Posted by sp...@apache.org.
Merge branch 'TINKERPOP-1877-master'


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/12479c66
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/12479c66
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/12479c66

Branch: refs/heads/master
Commit: 12479c66e32a5865ca7f3b23bb1d34462a6cf22f
Parents: f5d67e4 eacaf10
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Thu Feb 8 11:02:34 2018 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Thu Feb 8 11:02:34 2018 -0500

----------------------------------------------------------------------
 CHANGELOG.asciidoc                              |   1 +
 .../upgrade/release-3.2.x-incubating.asciidoc   |  24 ++++++-
 .../gremlin/util/TinkerGraphProvider.java       |   2 +
 gremlin-server/scripts/generate-all.groovy      |   6 +-
 .../driver/remote/RemoteGraphProvider.java      |   7 +-
 .../remote/gremlin-server-integration.yaml      |   3 +-
 .../apache/tinkerpop/gremlin/LoadGraphWith.java |  16 ++++-
 .../apache/tinkerpop/gremlin/TestHelper.java    |   3 +-
 .../traversal/step/branch/RepeatTest.java       |  25 +++++++-
 .../io/graphson/tinkerpop-sink-typed-v1d0.json  |   1 +
 .../io/graphson/tinkerpop-sink-typed-v2d0.json  |   1 +
 .../io/graphson/tinkerpop-sink-v1d0.json        |   1 +
 .../io/graphson/tinkerpop-sink-v2d0.json        |   1 +
 .../io/graphson/tinkerpop-sink-v3d0.json        |   1 +
 .../structure/io/gryo/tinkerpop-sink-v3d0.kryo  | Bin 0 -> 79 bytes
 .../gremlin/hadoop/HadoopGraphProvider.java     |   8 ++-
 .../tinkergraph/structure/TinkerFactory.java    |  15 +++++
 .../tinkergraph/TinkerGraphProvider.java        |   2 +
 .../structure/IoDataGenerationTest.java         |  64 +++++++++++++++++++
 19 files changed, 166 insertions(+), 15 deletions(-)
----------------------------------------------------------------------



[3/6] tinkerpop git commit: TINKERPOP-1877 Fixed path to kitchen sink graph for hadoop

Posted by sp...@apache.org.
TINKERPOP-1877 Fixed path to kitchen sink graph for hadoop


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/eacaf106
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/eacaf106
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/eacaf106

Branch: refs/heads/master
Commit: eacaf10612bd9122a0b7c0771c466160f30791d8
Parents: eb6bf21
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Thu Feb 1 14:24:03 2018 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Thu Feb 1 14:24:03 2018 -0500

----------------------------------------------------------------------
 .../org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/eacaf106/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
----------------------------------------------------------------------
diff --git a/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java b/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
index 79a039a..92c361f 100644
--- a/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
+++ b/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/HadoopGraphProvider.java
@@ -154,7 +154,7 @@ public class HadoopGraphProvider extends AbstractGraphProvider {
         } else if (graphData.equals(LoadGraphWith.GraphData.CREW)) {
             ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-crew" + type));
         } else if (graphData.equals(LoadGraphWith.GraphData.SINK)) {
-            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-sink." + type));
+            ((HadoopGraph) g).configuration().setInputLocation(PATHS.get("tinkerpop-sink" + type));
         } else {
             throw new RuntimeException("Could not load graph with " + graphData);
         }