AlCode
AlCode

Reputation: 565

SonarQube Error and some questions

I've set up SonarQube with the 2 minute installation guide.

I Have created a user which is not Admin.

Now I have run the analysis on the sample codes on the website and it is working fine.

However when i run it on my own code it gets the following error:

INFO: [JOURNAL_FLUSHER] WARNING Journal flush operation took 5,093ms last 8 cycl
es average is 636ms
Exception in thread "main" java.lang.OutOfMemoryError: GC overhead limit exceede
d
        at com.google.common.collect.ImmutableList.copyFromCollection(ImmutableL
ist.java:297)
        at com.google.common.collect.ImmutableList.copyOf(ImmutableList.java:260
)

I have no idea what this could be and also my sonar-project.properties looks like this:

# must be unique in a given SonarQube instance
sonar.projectKey=myTestProject
# this is the name displayed in the SonarQube UI
sonar.projectName=Selecta NL project Testing
sonar.projectVersion=1.0

# Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
# Since SonarQube 4.2, this property is optional if sonar.modules is set. 
# If not set, SonarQube starts looking for source code from the directory containing 
# the sonar-project.properties file.
sonar.sources=.

# Encoding of the source code. Default is default system encoding
#sonar.sourceEncoding=UTF-8

one more question, do I have to run CMD command to analyze always? If I set this up on a server does every developer need to open CMD and run this? How is the workflow working?

Upvotes: 0

Views: 233

Answers (1)

G. Ann - SonarSource Team
G. Ann - SonarSource Team

Reputation: 22804

This is telling you that the Java process which runs the analysis ran out of memory. You need to launch that process with arguments that give it more than the default memory allowances (E.G. -Xmx1280m -Xms512m -XX:MaxPermSize=256m).

Since you launch analysis from the command line using sonar-runner.bat, your cleanest option for passing these args is probably to set a %SONAR_RUNNER_OPTS% env var.

Upvotes: 1

Related Questions