Opened at 2026-03-03T02:54:10Z
Last modified at 2026-03-03T12:28:30Z
#1416 new todo
clarify lifecycle of the »Vessel«
| Reported by: | Ichthyostega | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | lumiera | Keywords: | architecture sanity QA |
| Sub Tickets: | #1145 | Parent Tickets: | #55, #195, #1146 |
Description
As Lumiera Architect,
I want all aspects of lifecycle well defined and handled precisely,
to ensure the overall structure of the application is well understood and plumb.
analysis of dark corners required
Initially the »application« was projected as a conglomerate of components, that all just need to be pulled up, flexibly and on-demand. And shutdown was deemed not necessary — as long as everything is always maintained in clean state, it suffices to „pull the plug“.
While the principles behind this approach seem commendable, it turned out that an application of this weight and complexity was not so easy to maintain. A core application was gradually established, and now the application is understood as a vessel, with clear boundaries and a backbone.
However, the audacity of the early days has left its mark: there is an unclear quagmire of dependencies between NoBug, AppLifecycle, the LifecycleRegistry, the lib::DependFactory, SyncClasslock and the unexpectedException-handler
Guidelines
- everything of a coordinating nature belongs into the Vessel, not the Library
- Library code should not expose automated management functionality
- an internal backbone can not be an external interface

An initial investigation implies the following changes
ON_BASIC_INITfunctionality of theLifecycleHookshould be reconsidered, in light of the findings in #1133. It looks like a clumsily implemented and incomplete Schwartz counternobug-init.hppinstall_unexpectedException_handler()in error-exception.cppnobug-init.hppseems ill-guided, in terms of architecture; as far as I can see, with the introduction ofZombieCheck, none of the problematic low-level-features needs any logging during the static-init/shutdown phaseZombieCheckshould additionally also print the warning message to STDERRLifecycleHookcould migrate up into the »Vessel«Another related theme is the usage of
lib::DependFactory. This clearly seems to be a facility that belongs into the »Vessel«. Not counting the confusion aroundSyncClasslockandnobug-init, there seem only three further usages from Library code:MultiFact— which in turn looks like an obsolete pipe dream from the early days ... it is used by thehandling-patterns.hpp, which were never really implemented (and likely never will); and it is used from thequery-resolver.hpp, which is a placeholder code for some not-yet implemented »centrepiece«test/tracking-allocator.cppuses some singleton pools for captured tracking information. This is a pattern that I would not implement this way any more. Rather, the user should explicitly create an instance of some diagnostics contextvisitor-dispatcher.hppalso exposes a singleton manager object, which implies it should move up into the »Vessel«