Uploaded image for project: 'TinkerPop'
  1. TinkerPop
  2. TINKERPOP-1562

Migrate ScriptEngine-related code to gremlin-core

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 3.2.3
    • Fix Version/s: 3.2.4
    • Component/s: groovy
    • Labels:

      Description

      Migrate classes and features of ScriptEngine to gremlin-core and GremlinScriptEngine. There is a minor breaking change where the ImportCustomizer class needs to become an interface. As the class itself played no real role in operations of 3.2.3 it's doubtful that this should be a big breaking change for users as no one was likely using it.

        Issue Links

          Activity

          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user asfgit closed the pull request at:

          https://github.com/apache/tinkerpop/pull/510

          Show
          githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/tinkerpop/pull/510
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user okram commented on the issue:

          https://github.com/apache/tinkerpop/pull/510

          VOTE +1.

          Show
          githubbot ASF GitHub Bot added a comment - Github user okram commented on the issue: https://github.com/apache/tinkerpop/pull/510 VOTE +1.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user dkuppitz commented on the issue:

          https://github.com/apache/tinkerpop/pull/510

          `docker/build.sh -t -i -n` succeeded. Haven't done a code review, no clue where to start and what to look for in 144 changed files. Anyway, Docker is happy and so am I.

          VOTE: +1

          Show
          githubbot ASF GitHub Bot added a comment - Github user dkuppitz commented on the issue: https://github.com/apache/tinkerpop/pull/510 `docker/build.sh -t -i -n` succeeded. Haven't done a code review, no clue where to start and what to look for in 144 changed files. Anyway, Docker is happy and so am I. VOTE: +1
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user spmallette commented on a diff in the pull request:

          https://github.com/apache/tinkerpop/pull/510#discussion_r91326812

          — Diff: hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/jsr223/HadoopGremlinPlugin.java —
          @@ -0,0 +1,153 @@
          +/*
          + * 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.hadoop.jsr223;
          +
          +import org.apache.hadoop.conf.Configuration;
          +import org.apache.hadoop.fs.FileSystem;
          +import org.apache.hadoop.io.IOUtils;
          +import org.apache.hadoop.io.compress.CodecPool;
          +import org.apache.hadoop.mapreduce.lib.input.SequenceFileInputFormat;
          +import org.apache.hadoop.mapreduce.lib.output.SequenceFileOutputFormat;
          +import org.apache.hadoop.util.ToolRunner;
          +import org.apache.tinkerpop.gremlin.hadoop.Constants;
          +import org.apache.tinkerpop.gremlin.hadoop.process.computer.mapreduce.MapReduceGraphComputer;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopConfiguration;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopEdge;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopElement;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopGraph;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopProperty;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertex;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertexProperty;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.FileSystemStorage;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.VertexWritable;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONInputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONOutputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordReader;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordWriter;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoInputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoOutputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordReader;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordWriter;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.script.ScriptInputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.util.ConfUtil;
          +import org.apache.tinkerpop.gremlin.jsr223.AbstractGremlinPlugin;
          +import org.apache.tinkerpop.gremlin.jsr223.BindingsCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.Customizer;
          +import org.apache.tinkerpop.gremlin.jsr223.DefaultImportCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.ImportCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.LazyBindingsCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.console.ConsoleCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.console.GremlinShellEnvironment;
          +import org.apache.tinkerpop.gremlin.jsr223.console.RemoteAcceptor;
          +
          +import javax.script.Bindings;
          +import javax.script.SimpleBindings;
          +import java.util.Collections;
          +import java.util.HashSet;
          +import java.util.Optional;
          +import java.util.Set;
          +
          +/**
          + * @author Marko A. Rodriguez (http://markorodriguez.com)
          + */
          +public final class HadoopGremlinPlugin extends AbstractGremlinPlugin {
          +
          + protected static String NAME = "tinkerpop.hadoop";
          +
          + private static final BindingsCustomizer bindings;
          +
          + private static final ImportCustomizer imports;
          +
          + private static final Set<String> appliesTo = new HashSet<>(Collections.singletonList("gremlin-groovy"));
          +
          + static {
          + try {
          + // TODO: most of the imports here were wildcarded, but we dont' allow that anymore - needs review
          + imports = DefaultImportCustomizer.build()
          + .addClassImports(
          + Configuration.class,
          + org.apache.hadoop.hdfs.DFSClient.class,
          + FileSystem.class,
          + ToolRunner.class,
          + IOUtils.class,
          + CodecPool.class,
          + SequenceFileInputFormat.class,
          + SequenceFileOutputFormat.class,
          + Constants.class,
          + HadoopConfiguration.class,
          + HadoopEdge.class,
          + HadoopElement.class,
          + HadoopGraph.class,
          + HadoopProperty.class,
          + HadoopVertex.class,
          + HadoopVertexProperty.class,
          + ConfUtil.class,
          + VertexWritable.class,
          + GraphSONInputFormat.class,
          + GraphSONOutputFormat.class,
          + GraphSONRecordReader.class,
          + GraphSONRecordWriter.class,
          + GryoInputFormat.class,
          + GryoOutputFormat.class,
          + GryoRecordReader.class,
          + GryoRecordWriter.class,
          + ScriptInputFormat.class,
          — End diff –

          done

          Show
          githubbot ASF GitHub Bot added a comment - Github user spmallette commented on a diff in the pull request: https://github.com/apache/tinkerpop/pull/510#discussion_r91326812 — Diff: hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/jsr223/HadoopGremlinPlugin.java — @@ -0,0 +1,153 @@ +/* + * 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.hadoop.jsr223; + +import org.apache.hadoop.conf.Configuration; +import org.apache.hadoop.fs.FileSystem; +import org.apache.hadoop.io.IOUtils; +import org.apache.hadoop.io.compress.CodecPool; +import org.apache.hadoop.mapreduce.lib.input.SequenceFileInputFormat; +import org.apache.hadoop.mapreduce.lib.output.SequenceFileOutputFormat; +import org.apache.hadoop.util.ToolRunner; +import org.apache.tinkerpop.gremlin.hadoop.Constants; +import org.apache.tinkerpop.gremlin.hadoop.process.computer.mapreduce.MapReduceGraphComputer; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopConfiguration; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopEdge; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopElement; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopGraph; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopProperty; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertex; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertexProperty; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.FileSystemStorage; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.VertexWritable; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONInputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONOutputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordReader; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordWriter; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoInputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoOutputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordReader; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordWriter; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.script.ScriptInputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.util.ConfUtil; +import org.apache.tinkerpop.gremlin.jsr223.AbstractGremlinPlugin; +import org.apache.tinkerpop.gremlin.jsr223.BindingsCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.Customizer; +import org.apache.tinkerpop.gremlin.jsr223.DefaultImportCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.ImportCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.LazyBindingsCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.console.ConsoleCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.console.GremlinShellEnvironment; +import org.apache.tinkerpop.gremlin.jsr223.console.RemoteAcceptor; + +import javax.script.Bindings; +import javax.script.SimpleBindings; +import java.util.Collections; +import java.util.HashSet; +import java.util.Optional; +import java.util.Set; + +/** + * @author Marko A. Rodriguez ( http://markorodriguez.com ) + */ +public final class HadoopGremlinPlugin extends AbstractGremlinPlugin { + + protected static String NAME = "tinkerpop.hadoop"; + + private static final BindingsCustomizer bindings; + + private static final ImportCustomizer imports; + + private static final Set<String> appliesTo = new HashSet<>(Collections.singletonList("gremlin-groovy")); + + static { + try { + // TODO: most of the imports here were wildcarded, but we dont' allow that anymore - needs review + imports = DefaultImportCustomizer.build() + .addClassImports( + Configuration.class, + org.apache.hadoop.hdfs.DFSClient.class, + FileSystem.class, + ToolRunner.class, + IOUtils.class, + CodecPool.class, + SequenceFileInputFormat.class, + SequenceFileOutputFormat.class, + Constants.class, + HadoopConfiguration.class, + HadoopEdge.class, + HadoopElement.class, + HadoopGraph.class, + HadoopProperty.class, + HadoopVertex.class, + HadoopVertexProperty.class, + ConfUtil.class, + VertexWritable.class, + GraphSONInputFormat.class, + GraphSONOutputFormat.class, + GraphSONRecordReader.class, + GraphSONRecordWriter.class, + GryoInputFormat.class, + GryoOutputFormat.class, + GryoRecordReader.class, + GryoRecordWriter.class, + ScriptInputFormat.class, — End diff – done
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user okram commented on a diff in the pull request:

          https://github.com/apache/tinkerpop/pull/510#discussion_r91200131

          — Diff: hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/jsr223/HadoopGremlinPlugin.java —
          @@ -0,0 +1,153 @@
          +/*
          + * 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.hadoop.jsr223;
          +
          +import org.apache.hadoop.conf.Configuration;
          +import org.apache.hadoop.fs.FileSystem;
          +import org.apache.hadoop.io.IOUtils;
          +import org.apache.hadoop.io.compress.CodecPool;
          +import org.apache.hadoop.mapreduce.lib.input.SequenceFileInputFormat;
          +import org.apache.hadoop.mapreduce.lib.output.SequenceFileOutputFormat;
          +import org.apache.hadoop.util.ToolRunner;
          +import org.apache.tinkerpop.gremlin.hadoop.Constants;
          +import org.apache.tinkerpop.gremlin.hadoop.process.computer.mapreduce.MapReduceGraphComputer;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopConfiguration;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopEdge;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopElement;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopGraph;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopProperty;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertex;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertexProperty;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.FileSystemStorage;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.VertexWritable;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONInputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONOutputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordReader;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordWriter;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoInputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoOutputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordReader;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordWriter;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.io.script.ScriptInputFormat;
          +import org.apache.tinkerpop.gremlin.hadoop.structure.util.ConfUtil;
          +import org.apache.tinkerpop.gremlin.jsr223.AbstractGremlinPlugin;
          +import org.apache.tinkerpop.gremlin.jsr223.BindingsCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.Customizer;
          +import org.apache.tinkerpop.gremlin.jsr223.DefaultImportCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.ImportCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.LazyBindingsCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.console.ConsoleCustomizer;
          +import org.apache.tinkerpop.gremlin.jsr223.console.GremlinShellEnvironment;
          +import org.apache.tinkerpop.gremlin.jsr223.console.RemoteAcceptor;
          +
          +import javax.script.Bindings;
          +import javax.script.SimpleBindings;
          +import java.util.Collections;
          +import java.util.HashSet;
          +import java.util.Optional;
          +import java.util.Set;
          +
          +/**
          + * @author Marko A. Rodriguez (http://markorodriguez.com)
          + */
          +public final class HadoopGremlinPlugin extends AbstractGremlinPlugin {
          +
          + protected static String NAME = "tinkerpop.hadoop";
          +
          + private static final BindingsCustomizer bindings;
          +
          + private static final ImportCustomizer imports;
          +
          + private static final Set<String> appliesTo = new HashSet<>(Collections.singletonList("gremlin-groovy"));
          +
          + static {
          + try {
          + // TODO: most of the imports here were wildcarded, but we dont' allow that anymore - needs review
          + imports = DefaultImportCustomizer.build()
          + .addClassImports(
          + Configuration.class,
          + org.apache.hadoop.hdfs.DFSClient.class,
          + FileSystem.class,
          + ToolRunner.class,
          + IOUtils.class,
          + CodecPool.class,
          + SequenceFileInputFormat.class,
          + SequenceFileOutputFormat.class,
          + Constants.class,
          + HadoopConfiguration.class,
          + HadoopEdge.class,
          + HadoopElement.class,
          + HadoopGraph.class,
          + HadoopProperty.class,
          + HadoopVertex.class,
          + HadoopVertexProperty.class,
          + ConfUtil.class,
          + VertexWritable.class,
          + GraphSONInputFormat.class,
          + GraphSONOutputFormat.class,
          + GraphSONRecordReader.class,
          + GraphSONRecordWriter.class,
          + GryoInputFormat.class,
          + GryoOutputFormat.class,
          + GryoRecordReader.class,
          + GryoRecordWriter.class,
          + ScriptInputFormat.class,
          — End diff –

          We also need `ScriptOutputFormat.class`. And for safety, `ScriptRecordReader` and `ScriptRecordWriter`.

          Show
          githubbot ASF GitHub Bot added a comment - Github user okram commented on a diff in the pull request: https://github.com/apache/tinkerpop/pull/510#discussion_r91200131 — Diff: hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/jsr223/HadoopGremlinPlugin.java — @@ -0,0 +1,153 @@ +/* + * 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.hadoop.jsr223; + +import org.apache.hadoop.conf.Configuration; +import org.apache.hadoop.fs.FileSystem; +import org.apache.hadoop.io.IOUtils; +import org.apache.hadoop.io.compress.CodecPool; +import org.apache.hadoop.mapreduce.lib.input.SequenceFileInputFormat; +import org.apache.hadoop.mapreduce.lib.output.SequenceFileOutputFormat; +import org.apache.hadoop.util.ToolRunner; +import org.apache.tinkerpop.gremlin.hadoop.Constants; +import org.apache.tinkerpop.gremlin.hadoop.process.computer.mapreduce.MapReduceGraphComputer; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopConfiguration; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopEdge; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopElement; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopGraph; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopProperty; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertex; +import org.apache.tinkerpop.gremlin.hadoop.structure.HadoopVertexProperty; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.FileSystemStorage; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.VertexWritable; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONInputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONOutputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordReader; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.graphson.GraphSONRecordWriter; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoInputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoOutputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordReader; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.gryo.GryoRecordWriter; +import org.apache.tinkerpop.gremlin.hadoop.structure.io.script.ScriptInputFormat; +import org.apache.tinkerpop.gremlin.hadoop.structure.util.ConfUtil; +import org.apache.tinkerpop.gremlin.jsr223.AbstractGremlinPlugin; +import org.apache.tinkerpop.gremlin.jsr223.BindingsCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.Customizer; +import org.apache.tinkerpop.gremlin.jsr223.DefaultImportCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.ImportCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.LazyBindingsCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.console.ConsoleCustomizer; +import org.apache.tinkerpop.gremlin.jsr223.console.GremlinShellEnvironment; +import org.apache.tinkerpop.gremlin.jsr223.console.RemoteAcceptor; + +import javax.script.Bindings; +import javax.script.SimpleBindings; +import java.util.Collections; +import java.util.HashSet; +import java.util.Optional; +import java.util.Set; + +/** + * @author Marko A. Rodriguez ( http://markorodriguez.com ) + */ +public final class HadoopGremlinPlugin extends AbstractGremlinPlugin { + + protected static String NAME = "tinkerpop.hadoop"; + + private static final BindingsCustomizer bindings; + + private static final ImportCustomizer imports; + + private static final Set<String> appliesTo = new HashSet<>(Collections.singletonList("gremlin-groovy")); + + static { + try { + // TODO: most of the imports here were wildcarded, but we dont' allow that anymore - needs review + imports = DefaultImportCustomizer.build() + .addClassImports( + Configuration.class, + org.apache.hadoop.hdfs.DFSClient.class, + FileSystem.class, + ToolRunner.class, + IOUtils.class, + CodecPool.class, + SequenceFileInputFormat.class, + SequenceFileOutputFormat.class, + Constants.class, + HadoopConfiguration.class, + HadoopEdge.class, + HadoopElement.class, + HadoopGraph.class, + HadoopProperty.class, + HadoopVertex.class, + HadoopVertexProperty.class, + ConfUtil.class, + VertexWritable.class, + GraphSONInputFormat.class, + GraphSONOutputFormat.class, + GraphSONRecordReader.class, + GraphSONRecordWriter.class, + GryoInputFormat.class, + GryoOutputFormat.class, + GryoRecordReader.class, + GryoRecordWriter.class, + ScriptInputFormat.class, — End diff – We also need `ScriptOutputFormat.class`. And for safety, `ScriptRecordReader` and `ScriptRecordWriter`.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user spmallette commented on the issue:

          https://github.com/apache/tinkerpop/pull/510

          @okram one thing that could use your explict review here - we lost the ability to do wildcard imports given the work you did on `CoreImports` for gremlin-python. Some plugins used a lot of wildcards, specifically the hadoop plugin:

          https://github.com/apache/tinkerpop/blob/90f427c8dc11636a5884e6cca3c0a22249d26576/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/jsr223/HadoopGremlinPlugin.java

          I didn't go through hadoop APIs to add all the classes that were wildcarded. can you please give a review to see if anything else should be added there?

          Show
          githubbot ASF GitHub Bot added a comment - Github user spmallette commented on the issue: https://github.com/apache/tinkerpop/pull/510 @okram one thing that could use your explict review here - we lost the ability to do wildcard imports given the work you did on `CoreImports` for gremlin-python. Some plugins used a lot of wildcards, specifically the hadoop plugin: https://github.com/apache/tinkerpop/blob/90f427c8dc11636a5884e6cca3c0a22249d26576/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/jsr223/HadoopGremlinPlugin.java I didn't go through hadoop APIs to add all the classes that were wildcarded. can you please give a review to see if anything else should be added there?
          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user spmallette opened a pull request:

          https://github.com/apache/tinkerpop/pull/510

          TINKERPOP-1562 Migrate ScriptEngine-related code to gremlin-core

          https://issues.apache.org/jira/browse/TINKERPOP-1562

          Apologies in advance - this is a fat, nasty PR and I doubt there would have been a way to break this up into smaller bits of work. Every change I made ended up creating new branches of stuff that needed to be touched. As it turns out `ScriptEngine` stuff was deeply nested into all areas of the code base and unraveling it all into a way that was non-breaking for 3.2.x was non-trivial.

          The core of this work focuses on:

          • Moving `ScriptEngine` and `GremlinPlugin` related stuff out of gremlin-groovy down to gremlin-core.
          • Given the above change that meant:
            • Taking each existing gremlin-groovy based `GremlinPlugin` (hadoop, giraph, gephi, etc) and developing a parallel plugin based on gremlin-core.
            • Making it so that gremlin server/console could utilize either plugin type (gremlin-server does this through a separate configuration option in gremlin-server.yaml and the console does this through a system variable that you could add to gremlin.sh (`-Dplugins=v3d3`)
            • Deprecating lots of odds and ends to allow me to move classes around. The deprecation approach was more tedious and leads to some dead code, but it was a nice way to evolve this change more slowly and intelligently. It also taught me that we should be more watchful of "public class" scope. If just a fraction of these classes that I deprecated (which no one probably uses anyway) had been package scope this work would have been much easier.

          The testing for this body of work involved:

          • `mvn clean install` with integration tests
          • `docker/build.sh -t -i -n`
          • `process-docs.sh`
          • manual testing:
            • every plugin in both versions
            • specific testing of the dependency grabber via `:install` for the console and `-i` in gremlin server

          For the most part I didn't provide a lot of docs for this because I don't think we need to publish this for 3.2.x. These changes essentially just set the stage for use to use them in full in 3.3.0. I'll do some separate smaller PRs for 3.3.0 work around this that will include doc updates as I remove the deprecated code I've created here.

          VOTE +1

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/apache/tinkerpop TINKERPOP-1562

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/tinkerpop/pull/510.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #510


          commit aca81c011c1d6e2df9be8a0b4085db6987a1839a
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-17T21:47:31Z

          TINKERPOP-1562 Initial effort to deprecate ScriptEngines.

          This opens up some options for how to move plugins up to gremlin-core (or deprecate them completely - not surehow that will flow yet). Anyway, this is a wip commit and a nice stop point.

          commit d14005e8826f556882b0f0db64bec5ef4130e6e3
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-18T10:34:00Z

          TINKERPOP-1562 More deprecation around methods on building GremlinExecutor that used ScriptEngines.

          commit 4943f1217eaed23030f88a5bdf225eeda7baa1ff
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T12:36:40Z

          TINKERPOP-1562 Add GreminServerGremlinModule for Gremlin Server specific imports

          Allow use of instance() as a way for GremlinModules to be instantiated.

          commit 8c7fada64e6d4d53b56ade84a0f4eb0acb49ecf8
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T12:54:35Z

          TINKERPOP-1562 Add GremlinModule for Giraph.

          commit f8fd64a650b4124eae89857ae1d7e66c05e00d5d
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T12:55:27Z

          TINKERPOP-1562 Moved GremlinServerGremlinModule to standard directory structure

          commit c182d1d47839c196a7592224fd83195b6a0a2993
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T15:56:21Z

          TINKERPOP-1562 Deprecated GiraphGremlinPlugin.

          commit a5f7daaf0ca90d4f3631c990720fbfd441e2e054
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T18:13:30Z

          TINKERPOP-1562 Move RemoteAcceptor related stuff to gremlin-core.

          commit 052f19f94a8534581226c9cdb6caebcc295d6820
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T18:15:02Z

          TINKERPOP-1562 Renamed GremlinModule to GremlinPlugin in gremlin-core

          commit d09cf9ce4ed42bc4da5d52438e896777ea5a667f
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T18:34:27Z

          TINKERPOP-1562 Bring back GremlinModule and deprecate it.

          GremlinModule was introduced in 3.2.3. Wasn't sure if GremlinModule was equal to a GremlinPlugin so I had named it differently. It was never promoted as a replacement for GremlinPlugin and it was never used in core infrastructure like Gremlin Console or Gremlin Server, but I figured it better to avoid breaking change and simply deprecate it for removal later.

          commit a28100fd1d0adcb3837aed99a177a3191d54d7cd
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-21T22:15:53Z

          TINKERPOP-1562 Start getting Console working with new plugin stuff

          Built adapters to get new RemoteAcceptor to behave as the old RemoteAcceptor and to get new GremlinPlugin to work as the old GremlinPlugin. Deprecated some classes and undeprecated others - still a pretty big WIP commit at this point but nothing appears to be broken.

          commit 11f57acf6d69ba0105e1ba2d3315e8aa3436d877
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T11:33:22Z

          TINKERPOP-1562 ImportCustomizer has become an interface

          This is a breaking change unfortunately, but this was not a feature that was published or used in 3.2.3 so I don't expect wide usage.

          commit 2fdd4b111c437f4ad9c8d293ae36ffad256da8b0
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T11:49:14Z

          TINKERPOP-1562 Change ScriptCustomizer to an interface.

          This class had been added as part of this branch so recasting it as an interface is non-breaking. Get PluggedIn to process the ScriptCustomizer.

          commit 32275a94952b6fbdb7f97f309b60155d799521bb
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T11:59:49Z

          TINKERPOP-1562 Rename "modules" as "plugin"

          commit 1c052e69046c6691d65649cc54f19bfa0ef5094f
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T14:39:37Z

          TINKERPOP-1562 Fixed problems related to loading new/old plugins

          Tested in Gremlin Console and it looks like the flag that will tell it to load one plugin version or the other is working properly.

          commit 05727e2c8de06aa01459e8c7ea51246a7d021dc4
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T14:42:12Z

          TINKERPOP-1562 Deprecated TinkerGraphGremlinPlugin.

          commit f88af07abd131e9973887d9945a438de985906c0
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T15:57:32Z

          TINKERPOP-1562 Added SparkGremlinPlugin

          SparkGremlinPlugin required binding injections so a BindingCustomizer was added along with two implementations - one for direct assignment and one for lazy assignment.

          commit 458c34111c078780be5393e901f85ee35e64145a
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T16:15:57Z

          TINKERPOP-1562 Add new Neo4j GremlinPlugin and deprecated old one

          commit a229885d74e953d0950f978b735f7896fbefb146
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T18:41:58Z

          TINKERPOP-1562 Add new HadoopGremlinPlugin and deprecated the old.

          Had to add some capabilities to plugin system to allow for passing of console environment bits (like groovysh for example).

          commit e57a240800097aeaa0bd82d60a97527d3fe7d653
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T19:20:11Z

          TINKERPOP-1562 Added new plugins for gremlin-groovy to replace deprecated ones.

          Specifically did SugarGremlinPlugin and CredentialsGrpahGremlinPlugin.

          commit 47a24d590c45fb74bb739215a324c44507377d18
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-22T21:35:16Z

          TINKERPOP-1562 Added gremlin-console plugins under the new model.

          Had to rework the PluggedIn adapters a bit so that they could better handle Console environment variable.s

          commit 469787a6c9b05fc88ca3d724ad314682078828f5
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-23T16:31:06Z

          TINKERPOP-1562 Minor changes to javadocs.

          Also, moved a public static field back to ImportCustomizer (after it became a interface).

          commit bea343e7d5e1fc0a865b45f29230c7e831735524
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-23T19:37:26Z

          TINKERPOP-1562 Added more tests for plugins/customizers

          commit daad833fbf7dc9d1173af380476b6f2cc5333807
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-23T20:36:13Z

          TINKERPOP-1562 Added more tests for the GremlnPluginAdapter

          commit 30a76e69af749223b2dc7b9a9b05030cde3a03b2
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-23T22:10:13Z

          TINKERPOP-1562 Abstracted groovysh/io to GremlinShellEnvironment

          The GremlinShellEnvironment provides a way to abstract groovysh and io classes (i.e. groovy specific classes) so that plugins don't need to depend on gremlin-groovy at all.

          commit 46ece9636b9f1a0a43726ebcd9222caed5f885d9
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-23T22:22:58Z

          TINKERPOP-1562 Added JSR-223 packages in gremin-core to core javadoc

          commit 6e6dd1b4c6a462ae97732553852cc98dbd486df4
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-24T13:11:35Z

          TINKERPOP-1562 Hooked up GremlinJythonScriptEngine to Customizers

          GremlnJythonScriptEngine is now initialized the same way that GremlinGroovyScriptEngine is.

          commit d6fcb927a79d1e6af637377f5ae7b5c66c98caf4
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-26T12:37:28Z

          TINKERPOP-1562 Get customizers for both python and jython.

          The customizers are combined to a set and therefore should only apply once. Presumably there wouldn't be a different set of customizers for one versus the other. If there were and you wanted them separate I guess you'd have to build two separate script engine instances.

          commit 9d0d1abe044e25e256ae3a852cf1452144abcfd7
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-28T21:51:12Z

          TINKERPOP=1562 Loaded "gremlin" imports in the scriptengines

          Rather than load them in the DefaultGremlinScriptEngineManager it seemed better to get them loaded in the engines themselves that way if someone opted to construct the GremlinScriptEngine directly the imports would be present.

          commit ce4d96cb92afa6095a1e2da8e6d0af789c5bcd46
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-29T14:21:49Z

          TINKERPOP-1562 Deprecated plugin exceptions.

          These are needed anymore under the revised plugin model in gremlin-core.

          commit 57ea73881076a6fb106d444f63f284c478714f1e
          Author: Stephen Mallette <spmva@genoprime.com>
          Date: 2016-11-29T14:39:10Z

          TINKERPOP-1562 Deprecated Artifact

          Moved it to a new home as the hole plugin package is going to go away in 3.3.0


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user spmallette opened a pull request: https://github.com/apache/tinkerpop/pull/510 TINKERPOP-1562 Migrate ScriptEngine-related code to gremlin-core https://issues.apache.org/jira/browse/TINKERPOP-1562 Apologies in advance - this is a fat, nasty PR and I doubt there would have been a way to break this up into smaller bits of work. Every change I made ended up creating new branches of stuff that needed to be touched. As it turns out `ScriptEngine` stuff was deeply nested into all areas of the code base and unraveling it all into a way that was non-breaking for 3.2.x was non-trivial. The core of this work focuses on: Moving `ScriptEngine` and `GremlinPlugin` related stuff out of gremlin-groovy down to gremlin-core. Given the above change that meant: Taking each existing gremlin-groovy based `GremlinPlugin` (hadoop, giraph, gephi, etc) and developing a parallel plugin based on gremlin-core. Making it so that gremlin server/console could utilize either plugin type (gremlin-server does this through a separate configuration option in gremlin-server.yaml and the console does this through a system variable that you could add to gremlin.sh (`-Dplugins=v3d3`) Deprecating lots of odds and ends to allow me to move classes around. The deprecation approach was more tedious and leads to some dead code, but it was a nice way to evolve this change more slowly and intelligently. It also taught me that we should be more watchful of "public class" scope. If just a fraction of these classes that I deprecated (which no one probably uses anyway) had been package scope this work would have been much easier. The testing for this body of work involved: `mvn clean install` with integration tests `docker/build.sh -t -i -n` `process-docs.sh` manual testing: every plugin in both versions specific testing of the dependency grabber via `:install` for the console and `-i` in gremlin server For the most part I didn't provide a lot of docs for this because I don't think we need to publish this for 3.2.x. These changes essentially just set the stage for use to use them in full in 3.3.0. I'll do some separate smaller PRs for 3.3.0 work around this that will include doc updates as I remove the deprecated code I've created here. VOTE +1 You can merge this pull request into a Git repository by running: $ git pull https://github.com/apache/tinkerpop TINKERPOP-1562 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/tinkerpop/pull/510.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #510 commit aca81c011c1d6e2df9be8a0b4085db6987a1839a Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-17T21:47:31Z TINKERPOP-1562 Initial effort to deprecate ScriptEngines. This opens up some options for how to move plugins up to gremlin-core (or deprecate them completely - not surehow that will flow yet). Anyway, this is a wip commit and a nice stop point. commit d14005e8826f556882b0f0db64bec5ef4130e6e3 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-18T10:34:00Z TINKERPOP-1562 More deprecation around methods on building GremlinExecutor that used ScriptEngines. commit 4943f1217eaed23030f88a5bdf225eeda7baa1ff Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T12:36:40Z TINKERPOP-1562 Add GreminServerGremlinModule for Gremlin Server specific imports Allow use of instance() as a way for GremlinModules to be instantiated. commit 8c7fada64e6d4d53b56ade84a0f4eb0acb49ecf8 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T12:54:35Z TINKERPOP-1562 Add GremlinModule for Giraph. commit f8fd64a650b4124eae89857ae1d7e66c05e00d5d Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T12:55:27Z TINKERPOP-1562 Moved GremlinServerGremlinModule to standard directory structure commit c182d1d47839c196a7592224fd83195b6a0a2993 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T15:56:21Z TINKERPOP-1562 Deprecated GiraphGremlinPlugin. commit a5f7daaf0ca90d4f3631c990720fbfd441e2e054 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T18:13:30Z TINKERPOP-1562 Move RemoteAcceptor related stuff to gremlin-core. commit 052f19f94a8534581226c9cdb6caebcc295d6820 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T18:15:02Z TINKERPOP-1562 Renamed GremlinModule to GremlinPlugin in gremlin-core commit d09cf9ce4ed42bc4da5d52438e896777ea5a667f Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T18:34:27Z TINKERPOP-1562 Bring back GremlinModule and deprecate it. GremlinModule was introduced in 3.2.3. Wasn't sure if GremlinModule was equal to a GremlinPlugin so I had named it differently. It was never promoted as a replacement for GremlinPlugin and it was never used in core infrastructure like Gremlin Console or Gremlin Server, but I figured it better to avoid breaking change and simply deprecate it for removal later. commit a28100fd1d0adcb3837aed99a177a3191d54d7cd Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-21T22:15:53Z TINKERPOP-1562 Start getting Console working with new plugin stuff Built adapters to get new RemoteAcceptor to behave as the old RemoteAcceptor and to get new GremlinPlugin to work as the old GremlinPlugin. Deprecated some classes and undeprecated others - still a pretty big WIP commit at this point but nothing appears to be broken. commit 11f57acf6d69ba0105e1ba2d3315e8aa3436d877 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T11:33:22Z TINKERPOP-1562 ImportCustomizer has become an interface This is a breaking change unfortunately, but this was not a feature that was published or used in 3.2.3 so I don't expect wide usage. commit 2fdd4b111c437f4ad9c8d293ae36ffad256da8b0 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T11:49:14Z TINKERPOP-1562 Change ScriptCustomizer to an interface. This class had been added as part of this branch so recasting it as an interface is non-breaking. Get PluggedIn to process the ScriptCustomizer. commit 32275a94952b6fbdb7f97f309b60155d799521bb Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T11:59:49Z TINKERPOP-1562 Rename "modules" as "plugin" commit 1c052e69046c6691d65649cc54f19bfa0ef5094f Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T14:39:37Z TINKERPOP-1562 Fixed problems related to loading new/old plugins Tested in Gremlin Console and it looks like the flag that will tell it to load one plugin version or the other is working properly. commit 05727e2c8de06aa01459e8c7ea51246a7d021dc4 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T14:42:12Z TINKERPOP-1562 Deprecated TinkerGraphGremlinPlugin. commit f88af07abd131e9973887d9945a438de985906c0 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T15:57:32Z TINKERPOP-1562 Added SparkGremlinPlugin SparkGremlinPlugin required binding injections so a BindingCustomizer was added along with two implementations - one for direct assignment and one for lazy assignment. commit 458c34111c078780be5393e901f85ee35e64145a Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T16:15:57Z TINKERPOP-1562 Add new Neo4j GremlinPlugin and deprecated old one commit a229885d74e953d0950f978b735f7896fbefb146 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T18:41:58Z TINKERPOP-1562 Add new HadoopGremlinPlugin and deprecated the old. Had to add some capabilities to plugin system to allow for passing of console environment bits (like groovysh for example). commit e57a240800097aeaa0bd82d60a97527d3fe7d653 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T19:20:11Z TINKERPOP-1562 Added new plugins for gremlin-groovy to replace deprecated ones. Specifically did SugarGremlinPlugin and CredentialsGrpahGremlinPlugin. commit 47a24d590c45fb74bb739215a324c44507377d18 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-22T21:35:16Z TINKERPOP-1562 Added gremlin-console plugins under the new model. Had to rework the PluggedIn adapters a bit so that they could better handle Console environment variable.s commit 469787a6c9b05fc88ca3d724ad314682078828f5 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-23T16:31:06Z TINKERPOP-1562 Minor changes to javadocs. Also, moved a public static field back to ImportCustomizer (after it became a interface). commit bea343e7d5e1fc0a865b45f29230c7e831735524 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-23T19:37:26Z TINKERPOP-1562 Added more tests for plugins/customizers commit daad833fbf7dc9d1173af380476b6f2cc5333807 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-23T20:36:13Z TINKERPOP-1562 Added more tests for the GremlnPluginAdapter commit 30a76e69af749223b2dc7b9a9b05030cde3a03b2 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-23T22:10:13Z TINKERPOP-1562 Abstracted groovysh/io to GremlinShellEnvironment The GremlinShellEnvironment provides a way to abstract groovysh and io classes (i.e. groovy specific classes) so that plugins don't need to depend on gremlin-groovy at all. commit 46ece9636b9f1a0a43726ebcd9222caed5f885d9 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-23T22:22:58Z TINKERPOP-1562 Added JSR-223 packages in gremin-core to core javadoc commit 6e6dd1b4c6a462ae97732553852cc98dbd486df4 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-24T13:11:35Z TINKERPOP-1562 Hooked up GremlinJythonScriptEngine to Customizers GremlnJythonScriptEngine is now initialized the same way that GremlinGroovyScriptEngine is. commit d6fcb927a79d1e6af637377f5ae7b5c66c98caf4 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-26T12:37:28Z TINKERPOP-1562 Get customizers for both python and jython. The customizers are combined to a set and therefore should only apply once. Presumably there wouldn't be a different set of customizers for one versus the other. If there were and you wanted them separate I guess you'd have to build two separate script engine instances. commit 9d0d1abe044e25e256ae3a852cf1452144abcfd7 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-28T21:51:12Z TINKERPOP=1562 Loaded "gremlin" imports in the scriptengines Rather than load them in the DefaultGremlinScriptEngineManager it seemed better to get them loaded in the engines themselves that way if someone opted to construct the GremlinScriptEngine directly the imports would be present. commit ce4d96cb92afa6095a1e2da8e6d0af789c5bcd46 Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-29T14:21:49Z TINKERPOP-1562 Deprecated plugin exceptions. These are needed anymore under the revised plugin model in gremlin-core. commit 57ea73881076a6fb106d444f63f284c478714f1e Author: Stephen Mallette <spmva@genoprime.com> Date: 2016-11-29T14:39:10Z TINKERPOP-1562 Deprecated Artifact Moved it to a new home as the hole plugin package is going to go away in 3.3.0

            People

            • Assignee:
              spmallette stephen mallette
              Reporter:
              spmallette stephen mallette
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development