saker.build icon indicating copy to clipboard operation
saker.build copied to clipboard

Add option for performing build without incremental state (CI mode)

Open Sipkab opened this issue 5 years ago • 0 comments

CI builds are often performed from a clean state, and rarely use incremental builds. This means that there is no reason for the build system to store and persist the incremental state between builds, as they aren't going to be used anyway.

There should be an option that instructs the build system to throw the incremental state that was created during the build away, and don't write it to the disk, or attempt to load it at the start of the build. This could improve the performance of the build, as well as could lower the memory usage somewhat.

This configuration options should also be available for build tasks to query, as they themselves can optimize their behaviour based on this.

Important to note that the build system itself shouldn't automatically configure itself for CI mode by querying environment variables or others. This option should be explicit.

Relevancy

This option could increase the performance of the saker.java.test task, as it will need less instrumentation to run. It would still need some instrumentation, as the file synchronization needs to be performed for the test cases. That could also be avoided if there was an option that marks the tests as not using files. In that case, any kind of instrumentation can be avoided.

Sipkab avatar Jan 08 '20 14:01 Sipkab