I am trying to use SonarQube to analyze a rather big project. I ran into an issue where it tells me I don't have enough memory so I set out to figure this out. I understand that I need to increase the amount of memory that Java can use, but I don't understand where it wants me to set the variable "SONAR_RUNNER_OPTS". It keeps telling me it's not set so it defaults to 1024. But that obviously wasn't enough.
So I ask, where do I set this variable? The variable appears to exist in the sonar-runner.bat file in my ...\.sonarqube\bin\sonar-runner\bin
folder but changing it doesn't do anything as the MSBuild.SonarQube.Runner.exe
deletes those files straight away to make them again, when I do the MSBuild.SonarQube.Runner.exe end
command.
What do I do?
Simply set SONAR_RUNNER_OPTS
as an environment variable (documentation).