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/11/12 17:06:17 UTC

[tinkerpop] branch master updated (a6bede9 -> 74f19e4)

This is an automated email from the ASF dual-hosted git repository.

spmallette pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/tinkerpop.git.


    from a6bede9  Merge branch 'tp33'
     add b4c0b9a  TINKERPOP-2050 Added :bytecode command to aid with debugging
     add a97caa7  TINKERPOP-2050 Added docs for :bytecode command
     add 0ce1675  TINKERPOP-2050 Support multi-line commands for :bytecode
     add 40c5896  TINKERPOP-2050 Removed the eval/submit options on :bytecode
     new e895a1d  Merge branch 'TINKERPOP-2050' into tp33
     new 74f19e4  Merge branch 'tp33'

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 CHANGELOG.asciidoc                                 |  1 +
 docs/src/reference/gremlin-applications.asciidoc   | 15 +++++
 docs/src/upgrade/release-3.3.x.asciidoc            | 21 +++++++
 .../tinkerpop/gremlin/console/Console.groovy       |  6 +-
 .../console/commands/BytecodeCommand.groovy        | 64 ++++++++++++++++++++++
 .../console/commands/BytecodeCommand.properties    |  7 +--
 6 files changed, 108 insertions(+), 6 deletions(-)
 create mode 100644 gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/commands/BytecodeCommand.groovy
 copy gremlin-archetype/gremlin-archetype-server/src/test/resources/projects/standard/archetype.properties => gremlin-console/src/main/resources/org/apache/tinkerpop/gremlin/console/commands/BytecodeCommand.properties (83%)


[tinkerpop] 02/02: Merge branch 'tp33'

Posted by sp...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

spmallette pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tinkerpop.git

commit 74f19e405c7c06cf4b131a84ec839e5ccfac8abd
Merge: a6bede9 e895a1d
Author: Stephen Mallette <sp...@genoprime.com>
AuthorDate: Mon Nov 12 12:06:01 2018 -0500

    Merge branch 'tp33'
    
    Conflicts:
    	gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy

 CHANGELOG.asciidoc                                 |  1 +
 docs/src/reference/gremlin-applications.asciidoc   | 15 +++++
 docs/src/upgrade/release-3.3.x.asciidoc            | 21 +++++++
 .../tinkerpop/gremlin/console/Console.groovy       |  6 +-
 .../console/commands/BytecodeCommand.groovy        | 64 ++++++++++++++++++++++
 .../console/commands/BytecodeCommand.properties    | 20 +++++++
 6 files changed, 125 insertions(+), 2 deletions(-)

diff --cc gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
index 3b4c7fd,89c37ad..9acf3a6
--- a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
+++ b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
@@@ -23,6 -21,8 +23,7 @@@ import groovy.cli.picocli.OptionAccesso
  import jline.TerminalFactory
  import jline.console.history.FileHistory
  
 -import org.apache.commons.cli.Option
+ import org.apache.tinkerpop.gremlin.console.commands.BytecodeCommand
  import org.apache.tinkerpop.gremlin.console.commands.GremlinSetCommand
  import org.apache.tinkerpop.gremlin.console.commands.InstallCommand
  import org.apache.tinkerpop.gremlin.console.commands.PluginCommand
@@@ -413,16 -412,17 +415,16 @@@ class Console 
  
          // note that the inclusion of -l is really a setting handled by gremlin.sh and not by Console class itself.
          // it is mainly listed here for informational purposes when the user starts things up with -h
 -        cli.with {
 -            h(longOpt: 'help', "Display this help message")
 -            v(longOpt: 'version', "Display the version")
 -            l("Set the logging level of components that use standard logging output independent of the Console")
 -            V(longOpt: 'verbose', "Enable verbose Console output")
 -            Q(longOpt: 'quiet', "Suppress superfluous Console output")
 -            D(longOpt: 'debug', "Enabled debug Console output")
 -            i(longOpt: 'interactive', argName: "SCRIPT ARG1 ARG2 ...", args: Option.UNLIMITED_VALUES, valueSeparator: ' ' as char, "Execute the specified script and leave the console open on completion")
 -            e(longOpt: 'execute', argName: "SCRIPT ARG1 ARG2 ...", args: Option.UNLIMITED_VALUES, valueSeparator: ' ' as char, "Execute the specified script (SCRIPT ARG1 ARG2 ...) and close the console on completion")
 -            C(longOpt: 'color', "Disable use of ANSI colors")
 -        }
 +        cli.h(type: Boolean, longOpt: 'help', "Display this help message")
 +        cli.v(type: Boolean,longOpt: 'version', "Display the version")
 +        cli.l("Set the logging level of components that use standard logging output independent of the Console")
 +        cli.V(type: Boolean, longOpt: 'verbose', "Enable verbose Console output")
 +        cli.Q(type: Boolean, longOpt: 'quiet', "Suppress superfluous Console output")
 +        cli.D(type: Boolean, longOpt: 'debug', "Enabled debug Console output")
 +        cli.i(type: List, longOpt: 'interactive', arity: "1..*", argName: "SCRIPT ARG1 ARG2 ...", "Execute the specified script and leave the console open on completion")
 +        cli.e(type: List, longOpt: 'execute', argName: "SCRIPT ARG1 ARG2 ...", "Execute the specified script (SCRIPT ARG1 ARG2 ...) and close the console on completion")
 +        cli.C(type: Boolean, longOpt: 'color', "Disable use of ANSI colors")
-         
++
          OptionAccessor options = cli.parse(args)
  
          if (options == null) {


[tinkerpop] 01/02: Merge branch 'TINKERPOP-2050' into tp33

Posted by sp...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

spmallette pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tinkerpop.git

commit e895a1d55e922fec0b59e775de908f68f05713d6
Merge: 4811f4e 40c5896
Author: Stephen Mallette <sp...@genoprime.com>
AuthorDate: Mon Nov 12 11:46:54 2018 -0500

    Merge branch 'TINKERPOP-2050' into tp33
    
    Conflicts:
    	docs/src/upgrade/release-3.3.x.asciidoc

 CHANGELOG.asciidoc                                 |  1 +
 docs/src/reference/gremlin-applications.asciidoc   | 15 +++++
 docs/src/upgrade/release-3.3.x.asciidoc            | 21 +++++++
 .../tinkerpop/gremlin/console/Console.groovy       |  2 +
 .../console/commands/BytecodeCommand.groovy        | 64 ++++++++++++++++++++++
 .../console/commands/BytecodeCommand.properties    | 20 +++++++
 6 files changed, 123 insertions(+)

diff --cc CHANGELOG.asciidoc
index 4f6c9d6,e652da9..f19ff82
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@@ -25,12 -25,9 +25,13 @@@ image::https://raw.githubusercontent.co
  
  This release also includes changes from <<release-3-2-11, 3.2.11>>.
  
+ * Added `:bytecode` command to help developers debugging `Bytecode`-based traversals.
  * Fixed `PersistedOutputRDD` to eager persist RDD by adding `count()` action calls.
 -* gremlin-python: the graphson deserializer for g:Set should return a python set
 +* Deserialized `g:Set` to a Python `Set` in GraphSON in `gremlin-python`.
 +* Display the remote stack trace in the Gremlin Console when scripts sent to the server fail.
 +* Added `AnonymousTraversalSource` which provides a more unified means of constructing a `TraversalSource`.
 +* Changed behavior of GraphSON deserializer in gremlin-python such that `g:Set` returns a Python `Set`.
 +* Changed behavior of `iterate()` in Python, Javascript and .NET to send `none()` thus avoiding unnecessary results being returned.
  
  [[release-3-3-4]]
  === TinkerPop 3.3.4 (Release Date: October 15, 2018)
diff --cc docs/src/upgrade/release-3.3.x.asciidoc
index caa65c2,f821aa5..3dd91fd
--- a/docs/src/upgrade/release-3.3.x.asciidoc
+++ b/docs/src/upgrade/release-3.3.x.asciidoc
@@@ -29,33 -29,27 +29,54 @@@ Please see the link:https://github.com/
  
  === Upgrading for Users
  
 +==== AnonymousTraversalSource
 +
 +The `AnonymousTraversalSource` provides for a more unified syntax for `TraversalSource` construction by placing greater
 +user emphasis on the creation of the source rather than the `Graph` it is connected to. It has a number of different
 +static `traversal()` methods available and when imported as:
 +
 +[source,java]
 +import static org.apache.tinkerpop.gremlin.process.traversal.AnonymousTraversalSource.traversal;
 +
 +allows `TraversalSource` construction syntax such as:
 +
 +[source,text]
 +----
 +gremlin> g = traversal().withGraph(TinkerFactory.createModern())
 +==>graphtraversalsource[tinkergraph[vertices:6 edges:6], standard]
 +gremlin> g = traversal().withRemote('conf/remote-graph.properties')
 +==>graphtraversalsource[emptygraph[empty], standard]
 +gremlin> g = traversal().withRemote(DriverRemoteConnection.using('localhost',8182))
 +==>graphtraversalsource[emptygraph[empty], standard]
 +----
 +
 +Typically, this syntax is used for "remote" traversal construction for bytecode based requests, but has the option to
 +bind a local `Graph` instance to it as well. It doesn't save much typing to do so obviously, so it may not be best
 +used in that situation. Python, Javascript and .NET have similar syntax.
 +
 +See: link:https://issues.apache.org/jira/browse/TINKERPOP-2078[TINKERPOP-2078]
 +
+ ==== Bytecode Command
+ 
+ The Gremlin Console now has a new `:bytecode` command to help users work more directly with Gremlin bytecode. The
+ command is more of a debugging tool than something that would be used for every day purposes. It is sometimes helpful
+ to look at Gremlin bytecode directly and the process for viewing it in human readable format is not a single step
+ process. It is also not immediately clear how to convert bytecode to a Gremlin string. The `:bytecode` command aims to
+ help with both of these issues:
+ 
+ [source,text]
+ ----
+ gremlin> g = TinkerFactory.createModern().traversal()
+ ==>graphtraversalsource[tinkergraph[vertices:6 edges:6], standard]
+ gremlin> :bytecode from g.V().out('knows')  <1>
+ ==>{"@type":"g:Bytecode","@value":{"step":[["V"],["out","knows"]]}}
+ gremlin> :bytecode translate g {"@type":"g:Bytecode","@value":{"step":[["V"],["out","knows"]]}} <2>
+ ==>g.V().out("knows")
+ ----
+ 
+ See: link:https://issues.apache.org/jira/browse/TINKERPOP-2050[TINKERPOP-2050],
+ link:http://tinkerpop.apache.org/docs/3.3.5/reference/#_console_commands[Reference Documentation - Console Commands]
+ 
  == TinkerPop 3.3.4
  
  *Release Date: October 15, 2018*