Hey there.
To improve analysis speed, it’s important to first identify which steps are taking the most time. Check out this post:
Regarding caching, you asked:
What can we tweak to make the analysis run faster, and what do we need to do so that the server actually uses the cache?
In most situations, the server should use the cache automatically, as long as a valid cache exists. According to the documentation:
- Before an analysis, the SonarScanner downloads from the server the corresponding cache:
- For a branch analysis: the cache of the branch being analyzed.
- For a pull request analysis: the cache of the target branch.
- Or, as a fallback, the cache of the main branch.
…
Branches that are not scanned for more than seven consecutive days are considered inactive, and the server automatically deletes their cached data to free space in the database.
If you’d like specific advice rather than general suggestions, I’d suggest that you share the full scan logs (ensure any sensitive information is removed first)!