thread names to aid debugging

This commit is contained in:
Jakob Ketterl
2020-08-14 20:22:25 +02:00
parent 7e5ea6e065
commit 0030c6d656
7 changed files with 8 additions and 8 deletions

View File

@ -48,7 +48,7 @@ class Client(ABC):
# unset the queue object to free shared memory file descriptors
self.multithreadingQueue = None
threading.Thread(target=mp_passthru).start()
threading.Thread(target=mp_passthru, name="connection_mp_passthru").start()
def send(self, data):
try:

View File

@ -158,7 +158,7 @@ class DspManager(csdr.output):
write = writers[t]
threading.Thread(target=self.pump(read_fn, write)).start()
threading.Thread(target=self.pump(read_fn, write), name="dsp_pump_{}".format(t)).start()
def stop(self):
self.dsp.stop()

View File

@ -49,7 +49,7 @@ class Map(object):
loops = 0
time.sleep(60)
threading.Thread(target=removeLoop, daemon=True).start()
threading.Thread(target=removeLoop, daemon=True, name="map_removeloop").start()
super().__init__()
def broadcast(self, update):

View File

@ -32,7 +32,7 @@ class ServiceOutput(output, metaclass=ABCMeta):
parser = self.getParser()
parser.setDialFrequency(self.frequency)
target = self.pump(read_fn, parser.parse)
threading.Thread(target=target).start()
threading.Thread(target=target, name="service_output_receive").start()
class WsjtServiceOutput(ServiceOutput):

View File

@ -171,7 +171,7 @@ class SdrSource(ABC):
logger.debug("shut down with RC={0}".format(rc))
self.monitor = None
self.monitor = threading.Thread(target=wait_for_process_to_end)
self.monitor = threading.Thread(target=wait_for_process_to_end, name="source_monitor")
self.monitor.start()
retries = 1000