You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by GitBox <gi...@apache.org> on 2020/04/01 15:19:15 UTC

[GitHub] [tinkerpop] spmallette commented on a change in pull request #1264: gremlin-python: add session mode client

spmallette commented on a change in pull request #1264: gremlin-python: add session mode client
URL: https://github.com/apache/tinkerpop/pull/1264#discussion_r401697847
 
 

 ##########
 File path: gremlin-python/src/main/jython/gremlin_python/driver/serializer.py
 ##########
 @@ -53,6 +53,22 @@ def eval(self, args):
         return args
 
 
+class Session(Processor):
+
+    def authentication(self, args):
+        return args
+
+    def eval(self, args):
+        return args
+
+    def close(self, args):
+        # close session, 'gremlin' in args as tips and not be executed actually
+        gremlin = args.get('gremlin')
+        if not gremlin:
+            args['gremlin'] = 'session.close()'
 
 Review comment:
   As in the other languages, I'd prefer we not include any extra arguments to the "close" message. Please modify this python PR to match what was done on the other language PRs.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services