added 99 as special number for no processes
This commit is contained in:
parent
96aea579ac
commit
c57080711e
2 changed files with 2 additions and 2 deletions
|
@ -88,7 +88,7 @@ class Basic(Console):
|
|||
s.append('Full Node')
|
||||
elif isinstance(self.service, LightClient):
|
||||
s.append('Light Client')
|
||||
if conf.processes == -1:
|
||||
if conf.processes in (-1, 99):
|
||||
s.append('Threads Only')
|
||||
elif conf.processes == 0:
|
||||
s.append(f'{os.cpu_count()} Process(es)')
|
||||
|
|
|
@ -162,7 +162,7 @@ class Database:
|
|||
self.message_queue, self.stop_event
|
||||
)
|
||||
}
|
||||
if self.processes > 1:
|
||||
if self.processes > 1 and self.processes != 99:
|
||||
self.executor = ProcessPoolExecutor(max_workers=self.processes, **kwargs)
|
||||
else:
|
||||
self.executor = ThreadPoolExecutor(max_workers=1, **kwargs)
|
||||
|
|
Loading…
Reference in a new issue