Closed ghost closed 4 years ago
Hi, I have never tried running this in a server environment. Let me see if I can try to use your settings and replicate the problem
On Fri, 8 May 2020, 19:38 Nathan McCoy, notifications@github.com wrote:
I am trying to use ArangoDB as a community supported provider https://github.com/ArangoDB-Community/arangodb-tinkerpop-provider for Tinkerpop https://tinkerpop.apache.org/ so that I can use Gremlin in a Python project but I get the following error:
[ERROR] DefaultGremlinScriptEngineManager - Could not create GremlinScriptEngine for gremlin-groovy java.lang.IllegalStateException: javax.script.ScriptException: javax.script.ScriptException: groovy.lang.MissingPropertyException: No such property: graph for class: Script1
I have followed the Wiki to define the properties https://github.com/ArangoDB-Community/arangodb-tinkerpop-provider/wiki/Configuration and yaml https://github.com/ArangoDB-Community/arangodb-tinkerpop-provider/wiki/Server configuration files.
Here is my properties configuration conf/modern-arangodb.properties:
gremlin.graph = com.arangodb.tinkerpop.gremlin.structure.ArangoDBGraph gremlin.arangodb.conf.graph.db = tinkerpopgremlin.arangodb.conf.graph.name = modern gremlin.arangodb.conf.graph.vertex = Place gremlin.arangodb.conf.graph.edge = Transition gremlin.arangodb.conf.arangodb.hosts = 127.0.0.1:8529 gremlin.arangodb.conf.arangodb.user = root gremlin.arangodb.conf.arangodb.password = openSesame
Here is my yaml configuration conf/gremlin-server-arangodb.yaml:
host: localhost port: 8182 scriptEvaluationTimeout: 30000 channelizer: org.apache.tinkerpop.gremlin.server.channel.WebSocketChannelizer graphs: { modern: conf/modern-arangodb.properties} scriptEngines: { gremlin-groovy: { plugins: { org.apache.tinkerpop.gremlin.server.jsr223.GremlinServerGremlinPlugin: {}, com.arangodb.tinkerpop.gremlin.jsr223.ArangoDBGremlinPlugin: {}, org.apache.tinkerpop.gremlin.jsr223.ImportGremlinPlugin: {classImports: [java.lang.Math], methodImports: [java.lang.Math#*]}, org.apache.tinkerpop.gremlin.jsr223.ScriptFileGremlinPlugin: {files: [scripts/empty-sample.groovy]}}}} serializers:
- { className: org.apache.tinkerpop.gremlin.driver.ser.GryoMessageSerializerV3d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV3d0] }} # application/vnd.gremlin-v3.0+gryo
- { className: org.apache.tinkerpop.gremlin.driver.ser.GryoMessageSerializerV3d0, config: { serializeResultToString: true }} # application/vnd.gremlin-v3.0+gryo-stringd
- { className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerV3d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV3d0] }} # application/json
- { className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerV2d0, config: { ioRegistries: [org.apache.tinkerpop.gremlin.tinkergraph.structure.TinkerIoRegistryV2d0] }} # application/vnd.gremlin-v2.0+json
- { className: org.apache.tinkerpop.gremlin.driver.ser.GraphBinaryMessageSerializerV1 } # application/vnd.graphbinary-v1.0 processors:
- { className: org.apache.tinkerpop.gremlin.server.op.session.SessionOpProcessor, config: { sessionTimeout: 28800000 }}
- { className: org.apache.tinkerpop.gremlin.server.op.traversal.TraversalOpProcessor, config: { cacheExpirationTime: 600000, cacheMaxSize: 1000 }} metrics: { consoleReporter: {enabled: true, interval: 180000}, csvReporter: {enabled: true, interval: 180000, fileName: /tmp/gremlin-server-metrics.csv}, jmxReporter: {enabled: true}, slf4jReporter: {enabled: true, interval: 180000}} strictTransactionManagement: false idleConnectionTimeout: 0 keepAliveInterval: 0 maxInitialLineLength: 4096 maxHeaderSize: 8192 maxChunkSize: 8192 maxContentLength: 65536 maxAccumulationBufferComponents: 1024 resultIterationBatchSize: 64 writeBufferLowWaterMark: 32768 writeBufferHighWaterMark: 65536 ssl: { enabled: false}
I then use the ArangoDB docker image https://www.arangodb.com/download-major/docker/ (Version 3.6.3) and run:
docker run -p 8529:8529 -e ARANGO_ROOT_PASSWORD=openSesame arangodb/arangodb:3.6.3
Then I run the Gremlin Server (Version 3.4.6) and run:
GREMLIN_YAML=conf/gremlin-server-arangodb.yaml bin/gremlin-server.sh console
After which the terminal returns the aforementioned error No such property: graph for class: Script1
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ArangoDB-Community/arangodb-tinkerpop-provider/issues/61, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAQOU3OFOPUMOHKA4DRYN5DRQRGSZANCNFSM4M4L57XA .
Thank you @arcanefoam for your help.
I have tried this with apache tinkerpop gremlin server version 3.3.10
and I am having the same problem.
This was essentially a documentation problem. On the server configuration documentation, a graph named modern
is created in the graphs
section of the yaml
file, but the ScriptFileGremlinPlugin
uses scripts/empty-sample.groovy
which instantiates the graph traversal from a global object named graph
(which should be modern
by our configuration
The resolution was to update the respective yaml
and properties
files to match and leave the empty-sample.groovy
file alone.
I will suggest some edits to the wiki for this. In addition here is a stackoverflow post with a more detailed response, for those who may need it.
I am trying to use ArangoDB as a community supported provider for Tinkerpop so that I can use Gremlin in a Python project but I get the following error:
I have followed the Wiki to define the
properties
andyaml
configuration files.Here is my
properties
configurationconf/modern-arangodb.properties
:Here is my
yaml
configurationconf/gremlin-server-arangodb.yaml
:I then use the ArangoDB docker image (Version 3.6.3) and run:
Then I run the Gremlin Server (Version 3.4.6) and run:
After which the terminal returns the aforementioned error
No such property: graph for class: Script1