You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by dk...@apache.org on 2018/03/07 15:48:17 UTC

[23/50] tinkerpop git commit: Updated release docs

Updated release docs


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

Branch: refs/heads/TINKERPOP-1522
Commit: 7149f8e8c1c255420b19748632ee4d928480f2e2
Parents: 3201442
Author: Daniel Kuppitz <da...@hotmail.com>
Authored: Fri Mar 2 14:04:58 2018 -0700
Committer: Daniel Kuppitz <da...@hotmail.com>
Committed: Fri Mar 2 14:04:58 2018 -0700

----------------------------------------------------------------------
 docs/src/upgrade/release-3.4.x.asciidoc | 42 ++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7149f8e8/docs/src/upgrade/release-3.4.x.asciidoc
----------------------------------------------------------------------
diff --git a/docs/src/upgrade/release-3.4.x.asciidoc b/docs/src/upgrade/release-3.4.x.asciidoc
index ff7b458..5a355fa 100644
--- a/docs/src/upgrade/release-3.4.x.asciidoc
+++ b/docs/src/upgrade/release-3.4.x.asciidoc
@@ -28,3 +28,45 @@ NEED AN IMAGE
 Please see the link:https://github.com/apache/tinkerpop/blob/3.4.0/CHANGELOG.asciidoc#release-3-4-0[changelog] for a complete list of all the modifications that are part of this release.
 
 === Upgrading for Users
+
+==== Modifications to reducing barrier steps
+
+The behavior of `min()`, `max()`, `mean()` and `sum()` has been modified to return no result if there's no input. Previously these steps yielded the internal seed value:
+
+[source,groovy]
+----
+gremlin> g.V().values('foo').min()
+==>NaN
+gremlin> g.V().values('foo').max()
+==>NaN
+gremlin> g.V().values('foo').mean()
+==>NaN
+gremlin> g.V().values('foo').sum()
+==>0
+----
+
+These traversals will no longer emit a result. Note, that this also affects more complex scenarios, e.g. if these steps are used in `by()` modulators:
+
+[source,groovy]
+----
+gremlin> g.V().group().
+......1>   by(label).
+......2>   by(outE().values("weight").sum())
+==>[software:0,person:3.5]
+----
+
+Since software vertices have no outgoing edges and thus no weight values to sum, `software` will no longer show up in the result. In order to get the same result as before, one would
+have to add a `coalesce()`-step:
+
+[source,groovy]
+----
+gremlin> g.V().group().
+......1>   by(label).
+......2>   by(outE().values("weight").sum())
+==>[person:3.5]
+gremlin> 
+gremlin> g.V().group().
+......1>   by(label).
+......2>   by(coalesce(outE().values("weight"), constant(0)).sum())
+==>[software:0,person:3.5]
+----