public
Created

Gremlin Error: set a list property

  • Download Gist
gistfile1.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
This works...
 
```shell
$ curl -X POST -d '{"script": "return cities", "params":{"cities": ["dallas", "austin"]} }' -H "Content-Type: application/json" http://localhost:7474/db/data/ext/GremlinPlugin/graphdb/execute_script
 
[ "dallas", "austin" ]
```
 
This doesn't...
 
```shell
$ curl -X POST -d '{"script": "neo4j = g.getRawGraph(); g.setMaxBufferSize(0); g.startTransaction(); v = neo4j.createNode(); v.setProperty(\"cities\",cities); g.stopTransaction(TransactionalGraph.Conclusion.SUCCESS); return v; ", "params":{"cities": ["dallas", "austin"]} }' -H "Content-Type: application/json" http://localhost:7474/db/data/ext/GremlinPlugin/graphdb/execute_script
 
"javax.script.ScriptException: java.lang.IllegalArgumentException: Unknown property type on: [dallas, austin], class java.util.ArrayList"
```

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.