Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-12331

Failure at scanner startup when using an early access JRE (because of Gson)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 8.0
    • Component/s: Scanner
    • Labels:
      None
    • Edition:
      Community
    • Production Notes:
      None

      Description

      Gson fails to parse JRE versions when it is an early access release.

      Might be enough to upgrade Gson library.

       

      java.lang.ExceptionInInitializerError
      	at com.google.gson.internal.reflect.ReflectionAccessor.<clinit>(ReflectionAccessor.java:36)
      	at com.google.gson.internal.ConstructorConstructor.<init>(ConstructorConstructor.java:51)
      	at com.google.gson.Gson.<init>(Gson.java:205)
      	at com.google.gson.Gson.<init>(Gson.java:185)
      	at org.sonar.scanner.bootstrap.ScannerPluginInstaller.listInstalledPlugins(ScannerPluginInstaller.java:104)
      	at org.sonar.scanner.bootstrap.ScannerPluginInstaller.loadPlugins(ScannerPluginInstaller.java:76)
      	at org.sonar.scanner.bootstrap.ScannerPluginInstaller.installRemotes(ScannerPluginInstaller.java:60)
      	at org.sonar.scanner.bootstrap.ScannerPluginRepository.start(ScannerPluginRepository.java:59)
      	at org.sonar.core.platform.StartableCloseableSafeLifecyleStrategy.start(StartableCloseableSafeLifecyleStrategy.java:40)
      	at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
      	at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
      	at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
      	at org.picocontainer.behaviors.Stored.start(Stored.java:110)
      	at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1016)
      	at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1009)
      	at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:767)
      	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:135)
      	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(NativeMethodAccessorImpl.java:62)
      	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.base/java.lang.reflect.Method.invoke(Method.java:567)
      	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:185)
      	at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:137)
      	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)
      Caused by: java.lang.NumberFormatException: For input string: "14-ea"
      	at java.base/java.lang.NumberFormatException.forInputString(NumberFormatException.java:68)
      	at java.base/java.lang.Integer.parseInt(Integer.java:652)
      	at java.base/java.lang.Integer.parseInt(Integer.java:770)
      	at com.google.gson.util.VersionUtils.determineMajorJavaVersion(VersionUtils.java:28)
      	at com.google.gson.util.VersionUtils.<clinit>(VersionUtils.java:24)
      	... 32 more 

        Attachments

          Activity

            People

            Assignee:
            duarte.meneses Duarte Meneses
            Reporter:
            duarte.meneses Duarte Meneses
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: