tsdb import 相关
时间:2021-07-01 10:21:17
帮助过:4人阅读
!/usr/bin/python
__author__ =
‘mingwli‘
import syslog
import multiprocessing
from multiprocessing
import Pool
import pydevd
syslog.openlog(‘file: %s‘ %
"My file", 0, syslog.LOG_LOCAL0)
def write_log(f):
syslog.syslog(‘Log msg: %s‘ %
‘test msg‘)
pool = Pool(processes=20
)
result =
[]
mylist = range(0, 20
)
for df
in mylist:
result.append(pool.apply_async(write_log, (str(df))))
pool.close()
pool.join()
print "all done"
tsdb import 相关
标签: