Skip to content

Commit

Permalink
Merge pull request PaddlePaddle#1490 from felixhjh/dev_stop
Browse files Browse the repository at this point in the history
fix windows gid recording
  • Loading branch information
bjjwwang committed Nov 15, 2021
1 parent 3bea13c commit 0c48fcd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion python/paddle_serving_server/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
import os
import time
import json
import platform
from paddle_serving_server.env import CONF_HOME


Expand Down Expand Up @@ -91,7 +92,10 @@ def dump_pid_file(portList, model):
dump_pid_file([9494, 10082], 'serve')
'''
pid = os.getpid()
gid = os.getpgid(pid)
if platform.system() == "Windows":
gid = pid
else:
gid = os.getpgid(pid)
pidInfoList = []
filepath = os.path.join(CONF_HOME, "ProcessInfo.json")
if os.path.exists(filepath):
Expand Down

0 comments on commit 0c48fcd

Please sign in to comment.