TINKERPOP-1612 Removed mode for old plugin system in console

In 3.2.4 the new plugin system was introduced. It was designed to run parallel 
to the old so there was some extra code in the console to allow it to load 
either the old plugin system or the new. Since TinkerGraph has removed its 
plugin due to removal of gremlin-groovy as a dependency, the old plugin system 
had to be removed as well for 3.3.0 or else no tinkergraph stuff will load in 
the console.


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

Branch: refs/heads/TINKERPOP-1612
Commit: a579f7c648728558b006737c98ef42d81a964171
Parents: 25d3e7d
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Mon Jan 30 14:36:56 2017 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Fri Feb 3 12:56:33 2017 -0500

----------------------------------------------------------------------
 .../giraph/jsr223/GiraphGremlinPlugin.java      |  2 +-
 gremlin-console/src/main/ext/plugins.txt        |  6 +-
 .../tinkerpop/gremlin/console/Console.groovy    | 29 ++------
 .../tinkerpop/gremlin/console/Mediator.groovy   |  2 -
 .../console/commands/InstallCommand.groovy      | 14 +---
 .../gremlin/jsr223/CoreGremlinModule.java       | 62 ----------------
 .../tinkerpop/gremlin/jsr223/CoreImports.java   |  1 +
 .../DefaultGremlinScriptEngineManager.java      | 25 -------
 .../tinkerpop/gremlin/jsr223/GremlinModule.java | 74 --------------------
 .../jsr223/GremlinScriptEngineManager.java      |  8 ---
 .../jsr223/GremlinEnabledScriptEngineTest.java  | 25 -------
 11 files changed, 15 insertions(+), 233 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/giraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/giraph/jsr223/GiraphGremlinPlugin.java
----------------------------------------------------------------------
diff --git 
a/giraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/giraph/jsr223/GiraphGremlinPlugin.java
 
b/giraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/giraph/jsr223/GiraphGremlinPlugin.java
index ee49ed5..c512335 100644
--- 
a/giraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/giraph/jsr223/GiraphGremlinPlugin.java
+++ 
b/giraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/giraph/jsr223/GiraphGremlinPlugin.java
@@ -38,7 +38,7 @@ public final class GiraphGremlinPlugin extends 
AbstractGremlinPlugin {
     private static final String MODULE_NAME = "tinkerpop.giraph";
     private static final GiraphGremlinPlugin instance = new 
GiraphGremlinPlugin();
 
-    private GiraphGremlinPlugin() {
+    public GiraphGremlinPlugin() {
         super(MODULE_NAME, DefaultImportCustomizer.build().addClassImports(
                 EmptyOutEdges.class,
                 GiraphComputation.class,

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-console/src/main/ext/plugins.txt
----------------------------------------------------------------------
diff --git a/gremlin-console/src/main/ext/plugins.txt 
b/gremlin-console/src/main/ext/plugins.txt
index 2b1a2e7..7eb2b23 100644
--- a/gremlin-console/src/main/ext/plugins.txt
+++ b/gremlin-console/src/main/ext/plugins.txt
@@ -1,3 +1,3 @@
-org.apache.tinkerpop.gremlin.console.groovy.plugin.DriverGremlinPlugin
-org.apache.tinkerpop.gremlin.console.groovy.plugin.UtilitiesGremlinPlugin
-org.apache.tinkerpop.gremlin.tinkergraph.groovy.plugin.TinkerGraphGremlinPlugin
\ No newline at end of file
+org.apache.tinkerpop.gremlin.console.jsr223.DriverGremlinPlugin
+org.apache.tinkerpop.gremlin.console.jsr223.UtilitiesGremlinPlugin
+org.apache.tinkerpop.gremlin.tinkergraph.jsr223.TinkerGraphGremlinPlugin
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
----------------------------------------------------------------------
diff --git 
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
index 15d8208..9f51548 100644
--- 
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
@@ -30,8 +30,8 @@ import 
org.apache.tinkerpop.gremlin.console.commands.SubmitCommand
 import org.apache.tinkerpop.gremlin.console.commands.UninstallCommand
 import org.apache.tinkerpop.gremlin.console.plugin.PluggedIn
 import org.apache.tinkerpop.gremlin.groovy.loaders.GremlinLoader
-import org.apache.tinkerpop.gremlin.groovy.plugin.GremlinPlugin
 import org.apache.tinkerpop.gremlin.jsr223.CoreGremlinPlugin
+import org.apache.tinkerpop.gremlin.jsr223.GremlinPlugin
 import org.apache.tinkerpop.gremlin.jsr223.ImportCustomizer
 import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalExplanation
 import org.apache.tinkerpop.gremlin.structure.Edge
@@ -97,18 +97,10 @@ class Console {
         // hide output temporarily while imports execute
         showShellEvaluationOutput(false)
 
-        if (Mediator.useV3d3) {
-            def imports = (ImportCustomizer) 
CoreGremlinPlugin.instance().getCustomizers("gremlin-groovy").get()[0]
-            imports.classImports.collect { IMPORT_SPACE + it.canonicalName 
}.each { groovy.execute(it) }
-            imports.methodImports.collect { IMPORT_STATIC_SPACE + 
it.getDeclaringClass().getCanonicalName() + "." + it.name}.each{ 
groovy.execute(it) }
-            imports.enumImports.collect { IMPORT_STATIC_SPACE + 
it.getDeclaringClass().getCanonicalName() + "." + it.name()}.each{ 
groovy.execute(it) }
-        } else {
-            // add the default imports
-            new ConsoleImportCustomizerProvider().getCombinedImports().stream()
-                    .collect { IMPORT_SPACE + it }.each { groovy.execute(it) }
-            new 
ConsoleImportCustomizerProvider().getCombinedStaticImports().stream()
-                    .collect { IMPORT_STATIC_SPACE + it }.each { 
groovy.execute(it) }
-        }
+        def imports = (ImportCustomizer) 
CoreGremlinPlugin.instance().getCustomizers("gremlin-groovy").get()[0]
+        imports.classImports.collect { IMPORT_SPACE + it.canonicalName }.each 
{ groovy.execute(it) }
+        imports.methodImports.collect { IMPORT_STATIC_SPACE + 
it.getDeclaringClass().getCanonicalName() + "." + it.name}.each{ 
groovy.execute(it) }
+        imports.enumImports.collect { IMPORT_STATIC_SPACE + 
it.getDeclaringClass().getCanonicalName() + "." + it.name()}.each{ 
groovy.execute(it) }
 
         final InteractiveShellRunner runner = new 
InteractiveShellRunner(groovy, handlePrompt)
         runner.setErrorHandler(handleError)
@@ -124,16 +116,9 @@ class Console {
 
         // check for available plugins.  if they are in the "active" plugins 
strategies then "activate" them
         def activePlugins = Mediator.readPluginState()
-        def pluginClass = mediator.useV3d3 ? 
org.apache.tinkerpop.gremlin.jsr223.GremlinPlugin : GremlinPlugin
-        ServiceLoader.load(pluginClass, 
groovy.getInterp().getClassLoader()).each { plugin ->
+        ServiceLoader.load(GremlinPlugin, 
groovy.getInterp().getClassLoader()).each { plugin ->
             if (!mediator.availablePlugins.containsKey(plugin.class.name)) {
-                def pluggedIn
-
-                if (Mediator.useV3d3) {
-                    pluggedIn = new PluggedIn(new 
PluggedIn.GremlinPluginAdapter((org.apache.tinkerpop.gremlin.jsr223.GremlinPlugin)
 plugin, groovy, io), groovy, io, false)
-                } else {
-                    pluggedIn = new PluggedIn((GremlinPlugin) plugin, groovy, 
io, false)
-                }
+                def pluggedIn = new PluggedIn(new 
PluggedIn.GremlinPluginAdapter((GremlinPlugin) plugin, groovy, io), groovy, io, 
false)
 
                 mediator.availablePlugins.put(plugin.class.name, pluggedIn)
 

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Mediator.groovy
----------------------------------------------------------------------
diff --git 
a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Mediator.groovy
 
b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Mediator.groovy
index 18e8d58..d5f5a66 100644
--- 
a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Mediator.groovy
+++ 
b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Mediator.groovy
@@ -34,8 +34,6 @@ class Mediator {
 
     private static String LINE_SEP = System.getProperty("line.separator")
 
-    public static final boolean useV3d3 = System.getProperty("plugins", 
"v3d2") == "v3d3"
-
     public Mediator(final Console console) {
         this.console = console
     }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/commands/InstallCommand.groovy
----------------------------------------------------------------------
diff --git 
a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/commands/InstallCommand.groovy
 
b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/commands/InstallCommand.groovy
index c8a49df..57ecade 100644
--- 
a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/commands/InstallCommand.groovy
+++ 
b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/commands/InstallCommand.groovy
@@ -21,10 +21,10 @@ package org.apache.tinkerpop.gremlin.console.commands
 import org.apache.tinkerpop.gremlin.console.ConsoleFs
 import org.apache.tinkerpop.gremlin.console.Mediator
 import org.apache.tinkerpop.gremlin.console.plugin.PluggedIn
-import org.apache.tinkerpop.gremlin.groovy.plugin.GremlinPlugin
 import groovy.grape.Grape
 import org.apache.tinkerpop.gremlin.groovy.util.Artifact
 import org.apache.tinkerpop.gremlin.groovy.util.DependencyGrabber
+import org.apache.tinkerpop.gremlin.jsr223.GremlinPlugin
 import org.codehaus.groovy.tools.shell.CommandSupport
 import org.codehaus.groovy.tools.shell.Groovysh
 
@@ -64,17 +64,9 @@ class InstallCommand extends CommandSupport {
 
         // note that the service loader utilized the classloader from the 
groovy shell as shell class are available
         // from within there given loading through Grape.
-        def pluginClass = mediator.useV3d3 ? 
org.apache.tinkerpop.gremlin.jsr223.GremlinPlugin : GremlinPlugin
-        ServiceLoader.load(pluginClass, 
shell.getInterp().getClassLoader()).forEach { plugin ->
+        ServiceLoader.load(GremlinPlugin, 
shell.getInterp().getClassLoader()).forEach { plugin ->
             if (!mediator.availablePlugins.containsKey(plugin.class.name)) {
-
-                if (Mediator.useV3d3) {
-                    mediator.availablePlugins.put(plugin.class.name, new 
PluggedIn(new 
PluggedIn.GremlinPluginAdapter((org.apache.tinkerpop.gremlin.jsr223.GremlinPlugin)
 plugin, shell, io), shell, io, false))
-                } else {
-                    mediator.availablePlugins.put(plugin.class.name, new 
PluggedIn((GremlinPlugin) plugin, shell, io, false))
-                }
-
-                //mediator.availablePlugins.put(plugin.class.name, new 
PluggedIn(plugin, shell, io, false))
+                mediator.availablePlugins.put(plugin.class.name, new 
PluggedIn(new PluggedIn.GremlinPluginAdapter((GremlinPlugin) plugin, shell, 
io), shell, io, false))
                 if (plugin.requireRestart())
                     pluginsThatNeedRestart << plugin.name
             }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreGremlinModule.java
----------------------------------------------------------------------
diff --git 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreGremlinModule.java
 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreGremlinModule.java
deleted file mode 100644
index 369e171..0000000
--- 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreGremlinModule.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * 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.jsr223;
-
-import java.util.Optional;
-
-/**
- * This module is required for a {@code ScriptEngine} to be Gremlin-enabled.
- *
- * @author Stephen Mallette (http://stephen.genoprime.com)
- * @deprecated As of release 3.2.4, replaced by {@link CoreGremlinPlugin}.
- */
-@Deprecated
-public final class CoreGremlinModule implements GremlinModule {
-
-    private static final String MODULE_NAME = "tinkerpop.core";
-
-    private static final ImportCustomizer gremlinCore = 
DefaultImportCustomizer.build()
-            .addClassImports(CoreImports.getClassImports())
-            .addEnumImports(CoreImports.getEnumImports())
-            .addMethodImports(CoreImports.getMethodImports()).create();
-
-    private static final Customizer[] customizers = new Customizer[] 
{gremlinCore};
-
-    /**
-     * @deprecated As of 3.2.4, replaced by {@link #instance()} as this field 
will later become private.
-     */
-    @Deprecated
-    public static final CoreGremlinModule INSTANCE = new CoreGremlinModule();
-
-    private CoreGremlinModule() {}
-
-    public static CoreGremlinModule instance() {
-        return INSTANCE;
-    }
-
-    @Override
-    public Optional<Customizer[]> getCustomizers(final String 
scriptEngineName) {
-        return Optional.of(customizers);
-    }
-
-    @Override
-    public String getName() {
-        return MODULE_NAME;
-    }
-}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreImports.java
----------------------------------------------------------------------
diff --git 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreImports.java
 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreImports.java
index e7c1bfc..6d6d500 100644
--- 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreImports.java
+++ 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/CoreImports.java
@@ -118,6 +118,7 @@ import java.util.stream.Stream;
 
 /**
  * @author Marko A. Rodriguez (http://markorodriguez.com)
+ * @author Stephen Mallette (http://stephen.genoprime.com)
  */
 public final class CoreImports {
 

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/DefaultGremlinScriptEngineManager.java
----------------------------------------------------------------------
diff --git 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/DefaultGremlinScriptEngineManager.java
 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/DefaultGremlinScriptEngineManager.java
index 01b4957..96d3b00 100644
--- 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/DefaultGremlinScriptEngineManager.java
+++ 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/DefaultGremlinScriptEngineManager.java
@@ -97,14 +97,6 @@ public class DefaultGremlinScriptEngineManager implements 
GremlinScriptEngineMan
     private List<GremlinPlugin> plugins = new ArrayList<>();
 
     /**
-     * List of extensions for the {@link GremlinScriptEngineManager} which 
will be used to supply
-     * {@link Customizer} instances to {@link GremlinScriptEngineFactory} that 
are instantiated.
-     *
-     * @deprecated As of release 3.2.4, replaced by {@link #plugins}.
-     */
-    private List<GremlinModule> modules = new ArrayList<>();
-
-    /**
      * The effect of calling this constructor is the same as calling
      * {@code 
DefaultGremlinScriptEngineManager(Thread.currentThread().getContextClassLoader())}.
      */
@@ -130,26 +122,9 @@ public class DefaultGremlinScriptEngineManager implements 
GremlinScriptEngineMan
             return Stream.of(customizers.orElse(new Customizer[0]));
         }).collect(Collectors.toList());
 
-        // modules are deprecated in favor of GremlinPlugin - this line will 
eventually be removed
-        pluginCustomizers.addAll(modules.stream().flatMap(plugin -> {
-            final Optional<Customizer[]> customizers = 
plugin.getCustomizers(scriptEngineName);
-            return Stream.of(customizers.orElse(new Customizer[0]));
-        }).collect(Collectors.toList()));
-
-
         return pluginCustomizers;
     }
 
-    /**
-     * @deprecated As of release 3.2.4, replaced by {@link 
#addPlugin(GremlinPlugin)}.
-     */
-    @Override
-    @Deprecated
-    public void addModule(final GremlinModule module) {
-        // TODO: should modules be a set based on "name" to ensure uniqueness? 
not sure what bad stuff can happen with dupes
-        if (module != null) modules.add(module);
-    }
-
     @Override
     public void addPlugin(final GremlinPlugin plugin) {
         // TODO: should modules be a set based on "name" to ensure uniqueness? 
not sure what bad stuff can happen with dupes

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinModule.java
----------------------------------------------------------------------
diff --git 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinModule.java
 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinModule.java
deleted file mode 100644
index f05b51c..0000000
--- 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinModule.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * 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.jsr223;
-
-import org.apache.tinkerpop.gremlin.jsr223.console.RemoteAcceptor;
-
-import java.util.Optional;
-
-/**
- * @author Stephen Mallette (http://stephen.genoprime.com)
- * @deprecated As of release 3.2.4, replaced by {@link GremlinPlugin}.
- */
-@Deprecated
-public interface GremlinModule {
-    /**
-     * The name of the module.  This name should be unique (use a namespaced 
approach) as naming clashes will
-     * prevent proper module operations. Modules developed by TinkerPop will 
be prefixed with "tinkerpop."
-     * For example, TinkerPop's implementation of Giraph would be named 
"tinkerpop.giraph".  If Facebook were
-     * to do their own implementation the implementation might be called 
"facebook.giraph".
-     */
-    public String getName();
-
-    /**
-     * Some modules may require a restart of the plugin host for the 
classloader to pick up the features.  This is
-     * typically true of modules that rely on {@code Class.forName()} to 
dynamically instantiate classes from the
-     * root classloader (e.g. JDBC drivers that instantiate via @{code 
DriverManager}).
-     */
-    public default boolean requireRestart() {
-        return false;
-    }
-
-    /**
-     * Gets the list of all {@link Customizer} implementations to assign to a 
new {@link GremlinScriptEngine}. This is
-     * the same as doing {@code getCustomizers(null)}.
-     */
-    public default Optional<Customizer[]> getCustomizers(){
-        return getCustomizers(null);
-    }
-
-    /**
-     * Gets the list of {@link Customizer} implementations to assign to a new 
{@link GremlinScriptEngine}. The
-     * implementation should filter the returned {@code Customizers} according 
to the supplied name of the
-     * Gremlin-enabled {@code ScriptEngine}. By providing a filter, {@code 
GremlinModule} developers can have the
-     * ability to target specific {@code ScriptEngines}.
-     *
-     * @param scriptEngineName The name of the {@code ScriptEngine} or null to 
get all the available {@code Customizers}
-     */
-    public Optional<Customizer[]> getCustomizers(final String 
scriptEngineName);
-
-    /**
-     * Allows a plugin to utilize features of the {@code :remote} and {@code 
:submit} commands of the Gremlin Console.
-     * This method does not need to be implemented if the plugin is not meant 
for the Console for some reason or
-     * if it does not intend to take advantage of those commands.
-     */
-    public default Optional<RemoteAcceptor> remoteAcceptor() {
-        return Optional.empty();
-    }
-}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinScriptEngineManager.java
----------------------------------------------------------------------
diff --git 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinScriptEngineManager.java
 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinScriptEngineManager.java
index a48d761..eb4a2d3 100644
--- 
a/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinScriptEngineManager.java
+++ 
b/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinScriptEngineManager.java
@@ -118,14 +118,6 @@ public interface GremlinScriptEngineManager {
     public List<GremlinScriptEngineFactory> getEngineFactories();
 
     /**
-     * Add {@link GremlinModule} instances to customize newly created {@link 
GremlinScriptEngine} instances.
-     *
-     * @deprecated As of release 3.2.4, replaced by {@link 
#addPlugin(GremlinPlugin)}.
-     */
-    @Deprecated
-    public void addModule(final GremlinModule module);
-
-    /**
      * Add {@link GremlinPlugin} instances to customize newly created {@link 
GremlinScriptEngine} instances.
      */
     public void addPlugin(final GremlinPlugin plugin);

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/a579f7c6/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinEnabledScriptEngineTest.java
----------------------------------------------------------------------
diff --git 
a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinEnabledScriptEngineTest.java
 
b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinEnabledScriptEngineTest.java
index 5a880f8..e31a657 100644
--- 
a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinEnabledScriptEngineTest.java
+++ 
b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinEnabledScriptEngineTest.java
@@ -57,31 +57,6 @@ public class GremlinEnabledScriptEngineTest {
     }
 
     @Test
-    public void shouldSupportDeprecatedGremlinModules() throws Exception {
-        final GremlinScriptEngineManager mgr = new 
DefaultGremlinScriptEngineManager();
-        mgr.addModule(new GremlinModule() {
-            @Override
-            public String getName() {
-                return "test.junk";
-            }
-
-            @Override
-            public Optional<Customizer[]> getCustomizers(final String 
scriptEngineName) {
-                return Optional.of(new Customizer[] 
{DefaultImportCustomizer.build()
-                        .addClassImports(java.awt.Color.class)
-                        .addClassImports(java.sql.CallableStatement.class)
-                        .create() });
-            }
-        });
-
-        final GremlinScriptEngine scriptEngine = 
mgr.getEngineByName(ENGINE_TO_TEST);
-        final List<Class> classesToCheck = Arrays.asList(java.awt.Color.class, 
java.sql.CallableStatement.class);
-        for (Class clazz : classesToCheck) {
-            assertEquals(clazz, scriptEngine.eval(clazz.getSimpleName()));
-        }
-    }
-
-    @Test
     public void shouldReturnNoCustomizers() {
         final GremlinScriptEngineManager mgr = new 
DefaultGremlinScriptEngineManager();
         mgr.addPlugin(ImportGremlinPlugin.build()

Reply via email to