Skip to content

make-container-image: Parallelize image builds

Dduvall requested to merge main-7ac5-7ac5 into main-7ac5-d0c7

Perform each image build in a separate thread.

Introduced a base app.App class to standardize the creation of logger
instances and the logging of check_call output to each application
logger.

Implemented app.ThreadedApp that manages threading and separate
instances of a main application class. It provides a run method that
dispatches separate threads, creating a new application instance for
each thread to avoid pitfalls with self mutation (note I couldn't find
a current mutation but this is meant as a safeguard). A separate logger
is also created for each call to run to nicely prefix log messages and
subprocess output.

Writes to the shared report dict object are performed only after
acquiring the app.ThreadedApp mutex.

Bug: T370934

Merge request reports