mneethiraj commented on a change in pull request #75: ATLAS-3519: pool performance in hive lineage query URL: https://github.com/apache/atlas/pull/75#discussion_r344252885
########## File path: graphdb/janus/src/main/java/org/apache/atlas/repository/graphdb/janus/AtlasJanusGraph.java ########## @@ -330,13 +332,16 @@ public void exportToGson(OutputStream os) throws IOException { @Override public GremlinGroovyScriptEngine getGremlinScriptEngine() { + return scriptEngine; Review comment: GremlinGroovyScriptEngine returned here may not safe for use in multiple threads simultaneously i.e. side-effects of an execution in a thread might be visible in other threads. I suggest to use a ThreadLocal<GremlinGroovyScriptEngine>, to instantiate and use one script engine per thread. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services