I am attempting to implement a new graph implementation using gremlin-core according to the
instructions outlined here. This is going well. However, as part of the development environment, I also wanted to extend the implementation to make use of the gremlin-console and gremlin-server. I was able to get the gremlin-console working well by simply adding the gremlin-console maven dependency to my project and copying the configuration files from
gremlin-console bin and conf to my local project.
However, when I tried to do the same for gremlin-server, the server startup fails. In my Eclipse environment, I have a simple Maven module which depends on gremlin-server and has a local copy of the respective
gremlin-server bin, conf, script files. I try to start the server using conf/gremlin-server.yaml and get the following class
com.tinkerpop.gremlin.groovy.jsr223.ScriptEnginePluginAcceptor throws ScriptException while reading from UtilitiesGremlinPluginScript.groovy (included in the gremlin-server JAR) with the following details:
javax.script.ScriptException: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
Script3.groovy: 1: expecting '/', found '<EOF>' @ line 1, column 4.
/**
^
1 error
This issue is hidden by the subsequent NullPointerException when logging the ScriptException above (the returned IO is null):
<snip>
[INFO] GremlinServer - Initialized Gremlin thread pool. Threads in pool named with pattern gremlin-*
[INFO] ScriptEngines - Loaded nashorn ScriptEngine
[INFO] ScriptEngines - Loaded gremlin-groovy ScriptEngine
[INFO] GremlinExecutor - Getting dependencies for [[org.apache.commons, commons-math3, 3.2]]
[INFO] GremlinServer - Shutting down thread pools
[INFO] GremlinServer - Gremlin Server - shutdown complete
Exception in thread "main" java.lang.NullPointerException
at com.tinkerpop.gremlin.console.plugin.UtilitiesGremlinPlugin.pluginTo(UtilitiesGremlinPlugin.java:48)
at com.tinkerpop.gremlin.groovy.jsr223.GremlinGroovyScriptEngine.lambda$loadPlugins$0(GremlinGroovyScriptEngine.java:157)
at com.tinkerpop.gremlin.groovy.jsr223.GremlinGroovyScriptEngine$$Lambda$33/1334618867.accept(Unknown Source)
at java.util.ArrayList.forEach(ArrayList.java:1249)
at com.tinkerpop.gremlin.groovy.jsr223.GremlinGroovyScriptEngine.loadPlugins(GremlinGroovyScriptEngine.java:155)
at com.tinkerpop.gremlin.groovy.engine.ScriptEngines.lambda$loadPlugins$23(ScriptEngines.java:153)
at com.tinkerpop.gremlin.groovy.engine.ScriptEngines$$Lambda$32/1995505717.accept(Unknown Source)
at java.lang.Iterable.forEach(Iterable.java:75)
at com.tinkerpop.gremlin.groovy.engine.ScriptEngines.loadPlugins(ScriptEngines.java:151)
at com.tinkerpop.gremlin.groovy.engine.GremlinExecutor.lambda$createScriptEngines$15(GremlinExecutor.java:206)
at com.tinkerpop.gremlin.groovy.engine.GremlinExecutor$$Lambda$19/1213349904.accept(Unknown Source)
at com.tinkerpop.gremlin.groovy.engine.ScriptEngines.<init>(ScriptEngines.java:53)
at com.tinkerpop.gremlin.groovy.engine.GremlinExecutor.createScriptEngines(GremlinExecutor.java:185)
at com.tinkerpop.gremlin.groovy.engine.GremlinExecutor.<init>(GremlinExecutor.java:84)
at com.tinkerpop.gremlin.groovy.engine.GremlinExecutor.<init>(GremlinExecutor.java:50)
at com.tinkerpop.gremlin.groovy.engine.GremlinExecutor$Builder.create(GremlinExecutor.java:399)
at com.tinkerpop.gremlin.server.GremlinServer.initializeGremlinExecutor(GremlinServer.java:126)
at com.tinkerpop.gremlin.server.GremlinServer.run(GremlinServer.java:65)
at com.tinkerpop.gremlin.server.GremlinServer.main(GremlinServer.java:165)
</snip>
I would like to get a running instance of gremlin-server within my own application. Let me know if you can help me get that running.
Cheers,
Matt-