SonarLint for Eclipse 2022-03 hangs

  • Operating system: Both Linux and Windows
  • IDE name and flavor/env: Eclipse + JDT 2022-03
  • SonarLint plugin version:
  • Is connected mode used:
    • Connected to SonarCloud or SonarQube (and which version): SonarQube Version 9.4 (build 54424)

About once a day our SonarLint hangs. In Eclipse’s progress view we can see that it’s trying to analyze a file (which usually only takes a few seconds) for hours on ends. When this happens, multiple files are stuck in sonar’s queue.

Note that we also use Annotation Processing for use with AutoValue.

Please let us know how we can help you debug and fix this issue.

Hi @tivervac

What would help us to understand the issue is to take a thread dump when SonarLint hangs. There are many different ways to capture, I let you read this page.


Hi @Julien_HENRY

Since Eclipse 2021-12 (and likely the sonarlint release that went along with it), we’ve been suffering from our auto-generated AutoValue classes randomly receiving errors when we’re editing code near (but not in) the auto value. We have a feeling this SonarLint hang and the broken AutoValue is related. Without further ado, here’s the output of jstack -l <pid> and jstack <pid> during the hang.

jstack-l-pid.txt (329.2 KB)
jstack-pid.txt (309.0 KB)

You can also see that the sonarlint hanging is causing a memory leak in the following image.

Hi @tivervac

This is very useful, thanks!

It seems SonarLint is stuck while trying to sync connected mode local storage:

"Worker-18: Synchronize quality profiles with SonarQube/SonarCloud" #108 prio=5 os_prio=0 cpu=36477.84ms elapsed=8480.35s tid=0x00007f94b4034800 nid=0x347e waiting on condition  [0x00007f93d84ed000]
   java.lang.Thread.State: WAITING (parking)
	at jdk.internal.misc.Unsafe.park(java.base@11.0.12/Native Method)
	- parking to wait for  <0x0000000769c38200> (a java.util.concurrent.CompletableFuture$Signaller)
	at java.util.concurrent.locks.LockSupport.park(java.base@11.0.12/
	at java.util.concurrent.CompletableFuture$Signaller.block(java.base@11.0.12/
	at java.util.concurrent.ForkJoinPool.managedBlock(java.base@11.0.12/
	at java.util.concurrent.CompletableFuture.waitingGet(java.base@11.0.12/
	at java.util.concurrent.CompletableFuture.get(java.base@11.0.12/
	at org.sonarsource.sonarlint.core.serverapi.system.SystemApi.getStatusSync(
	at org.sonarsource.sonarlint.core.ConnectedSonarLintEngineImpl.sync(
	at org.sonarlint.eclipse.core.internal.engine.connected.ConnectedEngineFacade.lambda$35(
	at org.sonarlint.eclipse.core.internal.engine.connected.ConnectedEngineFacade$$Lambda$1180/0x0000000801147840.accept(Unknown Source)
	at org.sonarlint.eclipse.core.internal.engine.connected.ConnectedEngineFacade.doWithEngine(
	- locked <0x00000007491a1698> (a org.sonarlint.eclipse.core.internal.engine.connected.ConnectedEngineFacade)
	at org.sonarlint.eclipse.core.internal.engine.connected.ConnectedEngineFacade.sync(
	at org.sonarlint.eclipse.core.internal.engine.connected.ConnectedEngineFacade.syncAllProjects(

We can see that http requests are stuck:

"OkHttp" #16747 prio=5 os_prio=0 cpu=8.23ms elapsed=259.35s tid=0x00007f95a876b800 nid=0x3ae5 in Object.wait()  [0x00007f92863ea000]
   java.lang.Thread.State: WAITING (on object monitor)
	at java.lang.Object.wait(java.base@11.0.12/Native Method)
	- waiting on <no object reference available>
	at java.lang.Object.wait(java.base@11.0.12/
	at okhttp3.internal.http2.Http2Stream.waitForIo(
	at okhttp3.internal.http2.Http2Stream.takeHeaders(
	- waiting to re-lock in wait() <0x0000000769cabde0> (a okhttp3.internal.http2.Http2Stream)
	at okhttp3.internal.http2.Http2ExchangeCodec.readResponseHeaders(
	at okhttp3.internal.connection.Exchange.readResponseHeaders(
	at okhttp3.internal.http.CallServerInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at org.sonarlint.eclipse.core.internal.http.PreemptiveAuthenticatorInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at org.sonarlint.eclipse.core.internal.http.UserAgentInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.connection.ConnectInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.cache.CacheInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.BridgeInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.internal.http.RealInterceptorChain.proceed(
	at okhttp3.RealCall.getResponseWithInterceptorChain(
	at okhttp3.RealCall$AsyncCall.execute(
	at java.util.concurrent.ThreadPoolExecutor.runWorker(java.base@11.0.12/
	at java.util.concurrent.ThreadPoolExecutor$

This could be an issue in the httpclient library we are using (okhttp). For example I found this old issue report.

This might be due to something special in your network. Do you have any kind of proxy between you and your SonarQube server?

One the other hand, the fact that the “sync” is stuck in the background should not block SonarLint. We should be able to continue analyzing code with the previous version of the local storage. I have created a ticket to fix that, but I would really like to understand the original problem (= why is the sync process stuck) because this could remain a problem if SonarLint is not able to synchronize with SonarQube.

I prepared a custom build of SonarLint for Eclipse, with HTTP/2 disabled. Can you give a try and let me know if this is improving the situation?


We’ve installed your build, we’ll let you know in a few days whether this works better. Our network and computers don’t do anything special. The request should go through without issue. We’ve also always been able to update our bindings easily in the past.

@Julien_HENRY A few people at Sigasi have tried out your build. With that build everything works perfectly. What are the next steps here?

Hi @tivervac

Thanks for the follow up.

I created a ticket, and the fix will be part of next release (not planned yet, but should be around end of June):

1 Like

@Julien_HENRY any news on when the next release of the Eclipse plugin will be released? The custom build that solved the issue is no longer available…


We are at the end of a sprint on SonarLint Eclipse. The release should happen by the end of this week.

1 Like

A post was split to a new topic: SonarLint Eclipse hangs once per day