Как задедлочить петухон
#!/usr/bin/python
import threading
import time
import logging
from multiprocessing import Process
def process():
logging.info('I am process')
time.sleep(10)
def worker():
logging.info('Worker')
p = Process(target = process)
p.start()
p.join()
return
logging.basicConfig(level=logging.INFO)
logging.info("Starting")
threads = []
for i in range(5):
t = threading.Thread(target=worker)
threads.append(t)
logging.info("Starting thread...")
t.start()