Run task without cache vs cleaning
See original GitHub issueWe want to support a way for clients to run tasks, especially compiles, without cache, i.e. a non-incremental build.
One way to do this is to support a clean
request that asks to remove any products of a build target.
Another way would be to add a flag to the compile request, and potentially other tasks, that requests a full rebuild.
What considerations affect the choice of these options, and are there other options?
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
How to clear build cache for a specific task? - Help/Discuss
What I want to know is if a task says FROM-CACHE , how do I make it forcefully rebuild and run the actual...
Read more >android - How to clear gradle cache? - Stack Overflow
caching of all normal Android builder tasks is handled by Gradle. executing cleanBuildCache does not clear or affect the build cache in any...
Read more >Gradle Build Cache Basics - Baeldung
The Gradle build cache is semi-permanent storage that saves the build tasks' outputs. It enables the reuse of already generated artifacts ...
Read more >Understanding Different Gradle Caches for ... - Jason Atwood
There are several ways Gradle stores information between builds to drastically reduce subsequent build times. You may be familiar with some ...
Read more >Caching for faster builds | Gradle Enterprise Docs
Oftentimes, CI nodes and developers run the same tasks with the same set of changes. ... Clean build with outputs taken from the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
When I think of it more I agree that adding a
clean
request makes sense. A lot of build tools do support clean and I see value in having a tool-agnostic endpoint for this functionality. The build tool can declare that it doesn’t support clean during the initialize handshake.To fix this ticket I propose to add a new request endpoint
buildTarget/clean
Any suggestion what to put in
CleanResult
? We could adddef cleaned: Boolean
, wherecleaned=true
means the clean succeeded andcleaned=false
means nothing was cleaned. This would be consistent with LSPworkspace/applyEdit
https://microsoft.github.io/language-server-protocol/specification#workspace_applyEdit