This is an automated email from the ASF dual-hosted git repository.

xiaoyao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-heron.git


The following commit(s) were added to refs/heads/master by this push:
     new d05f6e9  Fix Heron Shell PID Extractor (#3528)
d05f6e9 is described below

commit d05f6e9fcd9646c931906e07de572c979a685720
Author: Xiaoyao Qian <[email protected]>
AuthorDate: Mon May 18 20:30:05 2020 -0700

    Fix Heron Shell PID Extractor (#3528)
    
    * Fix Heron Shell PID Extractor
    
    * read pid file
---
 heron/shell/src/python/handlers/pidhandler.py | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/heron/shell/src/python/handlers/pidhandler.py 
b/heron/shell/src/python/handlers/pidhandler.py
index da1c5c3..7d8b2a8 100644
--- a/heron/shell/src/python/handlers/pidhandler.py
+++ b/heron/shell/src/python/handlers/pidhandler.py
@@ -35,9 +35,5 @@ class PidHandler(tornado.web.RequestHandler):
   def get(self, instance_id):
     ''' get method '''
     self.content_type = 'application/json'
-    self.write(json.dumps(utils.chain([
-        ['ps', 'auxwwww'],
-        ['grep', instance_id],
-        ['grep', 'java'],
-        ['awk', '\'{print $2}\'']])).strip())
+    self.write(json.dumps(utils.chain([['cat', "%s.pid" % 
instance_id]])).strip())
     self.finish()

Reply via email to