如何在python中识别uwsgi进程和worker以进行日志记录?

时间:2019-07-27 19:25:20

标签: python-3.x uwsgi

我的uwsgi配置如下:

[uwsgi]
pidfile=/tmp/uwsgimaster.pid
processes=2
threads=4
enable-threads=true
log-master=true

在我的python脚本中,我可以使用 uwsgi.masterpid()

但是,每当我调用log.info时,我都想标识进程和线程。

如何实现?

0 个答案:

没有答案
相关问题