Currently for a c++ project, the cached analysis files are not being hit.
When I look at the “Run Code Analysis” step of the build, I see this:
2021-07-27T19:17:44.5678363Z INFO: Cache: 0/42 hits, 17945774 bytes
The build that was ran was the exact same branch as the branch that generated the cache file, so I would expect them all to be hit?
When the build starts, it grabs the cached files from a shared directory, and adds them to a temp directory on the build server.
Sonar setup for project:
Here is the powershell script for the build wrapper.
Note - that if I remove the /target:“clean;Build”, it works, however this piece was added, as other projects that use this script were not working. the build-wrapper-dump.json file was empty if the build was not cleaned.
“build-wrapper-win-x86-64.exe” --out-dir “$(Build.Repository.LocalPath)\output” “C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\amd64\msbuild.exe” “$(Build.Repository.LocalPath)$(SolutionName)” /p:Configuration=$(BuildConfiguration) /p:Platform=$(BuildPlatform) /target:“clean;Build”"
Please let me now if any other information or files are needed.