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 2016/02/13 00:56:06 UTC

[2/2] incubator-tinkerpop git commit: Merge remote-tracking branch 'origin/TINKERPOP-1039' into tp31

Merge remote-tracking branch 'origin/TINKERPOP-1039' into tp31


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

Branch: refs/heads/tp31
Commit: c1c6d6076fa88d041e8c7de4ef683ba6c873725e
Parents: f06cf66 e9966b3
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Fri Feb 12 18:43:23 2016 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Fri Feb 12 18:43:23 2016 -0500

----------------------------------------------------------------------
 CHANGELOG.asciidoc                              |   1 +
 .../src/reference/gremlin-applications.asciidoc | 103 +++++++++++++------
 .../upgrade/release-3.1.x-incubating.asciidoc   |  36 +++++++
 .../apache/tinkerpop/gremlin/driver/Client.java |   5 +-
 .../tinkerpop/gremlin/driver/Cluster.java       |  24 ++++-
 .../apache/tinkerpop/gremlin/driver/Tokens.java |  11 +-
 .../server/op/AbstractEvalOpProcessor.java      |  29 +++---
 .../server/GremlinDriverIntegrateTest.java      |  57 ++++++++--
 .../server/GremlinServerIntegrateTest.java      |  62 +++++++++++
 9 files changed, 273 insertions(+), 55 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/c1c6d607/CHANGELOG.asciidoc
----------------------------------------------------------------------
diff --cc CHANGELOG.asciidoc
index f4d02f7,de5bc67..98a184e
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@@ -26,19 -26,12 +26,20 @@@ image::https://raw.githubusercontent.co
  TinkerPop 3.1.2 (NOT OFFICIALLY RELEASED YET)
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  
 +* Fixed bug in "round robin" load balancing in `gremlin-driver` where requests were wrongly being sent to the same host.
 +* Prevented the spawning of unneeded reconnect tasks in `gremlin-driver` when a host goes offline.
 +* Fixed bug preventing `gremlin-driver` from reconnecting to Gremlin Server when it was restarted.
 +* Better handled errors that occurred on commits and serialization in Gremlin Server to first break the result iteration loop and to ensure commit errors were reported to the client.
 +* Added GraphSON serializers for the `java.time.*` classes.
 +* Improved the logging of the Gremlin Server REST endpoint as it pertained to script execution failures.
  * `TraversalExplanation` is now `Serializable` and registered with `GryoMapper`.
  * Deprecated `ScriptElementFactory` and made the local `StarGraph` globally available for `ScriptInputFormat`'s `parse()` method.
 +* Improved reusability of unique test directory creation in `/target` for `AbstractGraphProvider`, which was formerly only available to Neo4j, by adding `makeTestDirectory()`.
  * Optimized memory-usage in `TraversalVertexProgram`.
  * `Graph` instances are not merely "closed" at the end of tests, they are "cleared" via `GraphProvider.clear()`, which should in turn cleans up old data for an implementation.
+ * Expanded the Gremlin Server protocol to allow for transaction management on in-session requests and updated the `gremlin-driver` to take advantage of that.
  * Greatly reduced the amount of objects required in OLAP for the `ReducingBarrierStep` steps.
 +* Improved messages for the different distinct "timeouts" that a user can encounter with Gremlin Server.
  
  [[release-3.1.1-incubating]]
  TinkerPop 3.1.1 (Release Date: February 8, 2016)

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/c1c6d607/gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/Client.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/c1c6d607/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/op/AbstractEvalOpProcessor.java
----------------------------------------------------------------------
diff --cc gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/op/AbstractEvalOpProcessor.java
index 3e0c93e,e6cf2e6..1e37fa0
--- a/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/op/AbstractEvalOpProcessor.java
+++ b/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/op/AbstractEvalOpProcessor.java
@@@ -296,18 -295,10 +301,18 @@@ public abstract class AbstractEvalOpPro
                      // serialize here because in sessionless requests the serialization must occur in the same
                      // thread as the eval.  as eval occurs in the GremlinExecutor there's no way to get back to the
                      // thread that processed the eval of the script so, we have to push serialization down into that
 -                    serializeResponseMessage(ctx, msg, serializer, useBinary, aggregate, code);
 +                    Frame frame;
 +                    try {
 +                        frame = makeFrame(ctx, msg, serializer, useBinary, aggregate, code);
 +                    } catch (Exception ex) {
 +                        // exception is handled in makeFrame() - serialization error gets written back to driver
 +                        // at that point
 +                        if (manageTransactions) attemptRollback(msg, context.getGraphManager(), settings.strictTransactionManagement);
 +                        break;
 +                    }
  
                      // only need to reset the aggregation list if there's more stuff to write
-                     if (toIterate.hasNext())
+                     if (itty.hasNext())
                          aggregate = new ArrayList<>(resultIterationBatchSize);
                      else {
                          // iteration and serialization are both complete which means this finished successfully. note that

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/c1c6d607/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/server/GremlinServerIntegrateTest.java
----------------------------------------------------------------------