Closed Justintime50 closed 3 years ago
Speed improvements would also come if we had a workflow like Travis where Travis provided a pre-built container with most things already cached and downloading cached libraries only as needed inside the container - this however leaves out some flexibility that Harvey currently allows. Additionally, it would take a lot of effort to get a comprehensive container put together that spans various programming languages and versions with shells, paths, etc all ready to go.
This may have been helped slightly by switching from threads to processes as of #17
Switched back from processes to threads as it crashed Docker on older machines. No noticeable speed improvements on machines capable either (may have improvements on multiple concurrent builds, but a single build didn't see any improvements.)
Build stage
is INCREDIBLY fast - wahoo!Test stage
needs help. Because we are building unique images every single time with unique tags and unique containers - nothing can get cached. This is great for security and containing each persons tests to a unique container but is terrible on performance. Some scripts that only take 1-3 seconds to run are having their test stage take 15-20 seconds as all the overhead is on Docker.Deploy Stage
is fine, spinning up the container isn't the problem - it comes with tearing down the old one. Many containers will wait the default 10 seconds before stopping pending a "graceful shutdown" but many of the projects configured don't have a graceful shutdown in place and therefore simply wait the 10 default seconds. Killing containers immediately may not be a great idea because some projects will have a graceful shutdown - we need to find a happy median where we can shut down containers ASAP. This may require a per-project config.