ERROR: [BUILD BREAKER] API query limit (90) reached. Try increasing sonar.buildbreaker.queryMaxAttempts, sonar.buildbreaker.queryInterval, or both

Hi,

We are using SonarQube 7.9.6 and defined below configuration for build breaker:
API query interval (ms): 20000
API query max attempts: 90

We are getting intermittent error as below:

INFO: Waiting for report processing to complete...
INFO: Waiting for report processing to complete...
INFO: Waiting for report processing to complete...
ERROR: [BUILD BREAKER] API query limit (90) reached.  Try increasing sonar.buildbreaker.queryMaxAttempts, sonar.buildbreaker.queryInterval, or both.
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 33:24.906s
ERROR: Error during SonarScanner execution
INFO: Final Memory: 24M/108M
INFO: ------------------------------------------------------------------------
java.lang.IllegalStateException: Report processing is taking longer than the configured wait limit.
	at org.sonar.plugins.buildbreaker.QualityGateBreaker.getAnalysisId(QualityGateBreaker.java:220)
	at org.sonar.plugins.buildbreaker.QualityGateBreaker.execute(QualityGateBreaker.java:266)
	at org.sonar.scanner.postjob.PostJobWrapper.execute(PostJobWrapper.java:49)
	at org.sonar.scanner.postjob.PostJobsExecutor.execute(PostJobsExecutor.java:48)
	at org.sonar.scanner.postjob.PostJobsExecutor.execute(PostJobsExecutor.java:39)
	at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:368)
	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
	at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(GlobalContainer.java:141)
	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
	at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:73)
	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:67)
	at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.base/java.lang.reflect.Method.invoke(Unknown Source)
	at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
	at com.sun.proxy.$Proxy0.execute(Unknown Source)
	at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:189)
	at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:138)
	at org.sonarsource.scanner.cli.Main.execute(Main.java:112)
	at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
	at org.sonarsource.scanner.cli.Main.main(Main.java:61)

Can someone please help me to understand the cause of this failure ?
We are getting this error sometimes whereas rest job runs successfully without any error .

Thanks,
Vaibhav Jariwala

Hi,

First, your version is past EOL. You should upgrade to either the latest version or the current LTS at your earliest convenience. Your upgrade path is:

7.9.6 → 8.9.2 → 9.1 (last step optional)

You may find the Upgrade Guide and the LTS-to-LTS Upgrade Notes helpful. If you have questions about upgrading, feel free to open a new thread for that here.

Regarding your actual question, this error is from a plugin not supported by SonarSource, and once you upgrade you’ll find native mechanisms to get the same result.

 
HTH,
Ann

Hi @ganncamp ,
Thanks for replying back.
I do have 1 query:
If I upgrade Sonar from 7.9.6 to 8.9.2, will I get the same feature(if Quality Gate fails, stops further execution of CI pipeline job) in community edition without installing build breaker plugin?

Thanks,
Vaibhav Jariwala

Hi Vaibhav,

Yes, that’s available from Community Edition. The docs should help.

 
Ann