Upgraded lifecycles by putting session and thread registration inside the registry and handling initialization at the manageLifecycle level

This commit is contained in:
Lyncoln
2026-10-28 11:15:52 -04:00
parent 9d4e9d38ad
commit 3582c7b621
4 changed files with 49 additions and 40 deletions
+4 -19
View File
@@ -1,30 +1,15 @@
import threading
from .lifecyclemanager import registerLifecycle
from .lifecyclemanager import manageLifecycle
#threadlist = []
#threadnum = 0
def buildThread(module, lifecycles):
#global threadnum
#threadnum += 1
#threadname = f"thread.{threadnum}"
def buildThread(module):
thread = threading.Thread(
target=manageLifecycle,
args=(module, lifecycles),
args=(module,),
name=module.name
)
thread.start()
#print(lifecycles)
#registryname = thread.name
#registryvalue = thread
#lifecycles = registerLifecycle (module, lifecycles, thread.name, thread)
#threadlist.append(thread)
return thread, lifecycles
return thread