SonarQube Elastic Search deprecation warning - JAVA HOME

SonarQube CE 8.9.0 LTS, upgrade from 7.9.6
Java11/OpenJDK11U_openj9/jdk-11.0.11+9

On startup logs show:
INFO app[o.s.a.AppFileSystem] Cleaning or creating temp directory ./sonarqube-8.9.0.43852/…/temp
INFO app[o.s.a.es.EsSettings] Elasticsearch listening on [HTTP: 127.0.0.1:9101, TCP: 127.0.0.1:15701]
INFO app[o.s.a.ProcessLauncherImpl] Launch process[[key=‘es’, ipcIndex=1, logFilenamePrefix=es]] from [./sonarqube-8.9.0.43852/elasticsearch]: ./sonarqube-8.9.0.43852/elasticsearch/bin/elasticsearch
warning: usage of JAVA_HOME is deprecated, use ES_JAVA_HOME
INFO app[o.s.a.SchedulerImpl] Waiting for Elasticsearch to be up and running
warning: no-jdk distributions that do not bundle a JDK are deprecated and will be removed in a future release
INFO app[o.s.a.SchedulerImpl] Process[es] is up

There is no reference in bundled sonar.properties or sonar.sh to ES_JAVA_HOME.

In fact, only reference is the check in sonarqube-8.9.0.43852/elasticsearch/bin/elasticsearch-env.

Hey there.

This is an warning internal to how SonarQube bundles Elasticsearch which you can ignore. Nevertheless, I’ll ping the right person to find out if we ever plan to take care of this.

Indeed, we could fix that warning, thanks for raising this @ianw , I’ve created a ticket for it: SONAR-14960

If you are reviewing the use of JAVA_HOME, perhaps you can also consider the overall JAVA usage and review : Sonar.sh CMDJAVA loop issue ? When I raised that issue, it was more “does not work”, while now thoughts are also why is it not using JAVA_HOME?

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.