Skip to content

Upgrade the Plugin

Günter Wirth edited this page Aug 14, 2024 · 37 revisions

First follow the general Install the Plugin steps. On this page you will find special notes that must be taken into account when upgrading from a previous version:


                 Before you start, back up your SonarQube Database. 
      Upgrade problems are rare, but you'll want the backup if anything does happen.

Upgrade to 2.1.x

The version 2.1 of the cxx plugin is a minor update. Essentially, adjustments to the new SonarQube 9.9 LTS version and updates of the sensors to the latest rules of the corresponding tools took place.


     Important: If you are migrating from a version older than 2.0,
        make sure you also read the notes under 'Upgrade to 2.0.x'.

Important: In order not to lose the existing C++ (Community) Quality Profiles:

  1. Create a backup of your Quality Profile before installing the version 2.1 of the cxx plugin.
  2. Install the cxx plugin and restart the SonarQube Server
  3. Restore the modified Quality Profile.

Important: if you are using sonar.cxx.other.rules:

  1. Create a backup of your external rules before installing the cxx plugin.
  2. Install the cxx plugin and restart the SonarQube Server
  3. On new SonarQube servers restore the external rules before your are scaning a project. If you don’t do that issues are closed and reopened in New Code.

other hints:

  • tested and released for SonarQube 9.9 LTS with Java 17 (other versions are not supported)
  • tested and released for SonarQube 8.9 LTS with Java 11 (other versions are not supported)
  • If you're running SonarQube 9.9 with Java 11 as scanner runtime environment, the latest compatible SonarScanner version is 4.8.x. Later SonarScanner versions require Java 17 as runtime environment.
  • The plugin requires Java 11 or Java 17 on scanner side: install a Java version (e.g http://jdk.java.net/archive/) and update JAVA_HOME to point to the installation directory.
  • To avoid problems on a SonarQube Server with multiple C++ plugins, the CXX programming language sensor is disabled by default (sonar.cxx.file.suffixes=-). This configuration parameter must therefore be set explicitly now (default was previously .cxx,.cpp,.cc,.c,.hxx,.hpp,.hh,.h).
  • The configuration settings of the CXX programming language sensor can be found under Administration > CXX.
  • The configuration settings of the CXX report file sensors can be found under Administration > CXX External Analyzers.
  • The report sensors of the cxx plugin are able to read in C and C++ code. Code read in this way is displayed in SonarQube as the CXX programming language (language key=cxx). In addition, the CXX report sensors also support SonarCFamily for C/C++. Here C++ (language key=cpp) and C (language key=c) are supported. You have to decide which plugin you want to use for indexing the source code. In SonarQube, each file extension must be uniquely assigned to one programming language. When operating several C/C++ plugins in parallel, this must be taken into account during configuration (sonar.cxx.file.suffixes). Only one programming language sensor can read in a source file!
  • rules from external tools are deactivated in CXX Default Quality Profile Sonar way

Known Issues

For an up to date list of known issues see the issue tracker.

  • only tested with Java 11 and Java 17
    • Message "The plugin [cxx] does not support Java 1.8.0, UnsupportedClassVersionError". To solve this download OpenJDK 11 or 17 und unzip it (http://jdk.java.net/archive/). Point with the JAVA_HOME environment variable to the Java 11 or 17 location.
    • SonarQube nohup.log file item: Error: LinkageError occurred while loading main class org.sonar.application.App java.lang.UnsupportedClassVersionError: org/sonar/application/App has been compiled by a more recent version of the Java Runtime (class file version 61.0), this version of the Java Runtime only recognizes class file versions up to 55.0. To solve this download OpenJDK 17 and unzip it (http://jdk.java.net/archive/). Point with the JAVA_HOME environment variable to the Java 17 location.
  • In SonarQube, each file extension must be uniquely assigned to one programming language. When operating several C/C++ plugins in parallel, this must be taken into account during configuration. To avoid problems on a server with multiple C++ plugins, the CXX programming language sensor is disabled by default.
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable rules for external tools per default.
  • Message: "C++ cannot be analyzed with current SonarQube edition. Please consider upgrading...". SonarQube issues this message when an input file with the file extension .c, .cc, .cpp, .cxx or .c++ is read in the Community Edition. Select "Dismiss permanently" to continue without the message.
  • cxx-sslr-toolkit-x.y.z.jar is not a plugin. Do not copy it to the plugins folder. If the JAR file does not contain a SonarQube plugin, the following error message appears in the LOG file when the server is started: ERROR Web server startup failed java.lang.NullPointerException: Plugin key is missing from manifest.

Upgrade to 2.0.x

The version 2.0 of the cxx plugin is basically a completely new plugin. In version 2 the experiences from the previous versions have been considered and there were also numerous API and UI changes on the side of SonarQube that had to be taken into account.

Important: In order not to lose the existing C++ (Community) Quality Profiles:

  1. Create a backup of your Quality Profile before installing the version 2.0 of the cxx plugin.
  2. Replace <language>c++</language> with <language>cxx</language> in the backup file using a text editor.
  3. Replace repositoryKey in the backup file using a text editor:
    1. <repositoryKey>ClangTidy</repositoryKey> with
      <repositoryKey>clangtidy</repositoryKey>
    2. <repositoryKey>ClangSA</repositoryKey> with
      <repositoryKey>clangsa</repositoryKey>
    3. <repositoryKey>common-c++</repositoryKey> with
      <repositoryKey>common-cxx</repositoryKey>
  4. Install the cxx plugin and restart the SonarQube Server
  5. Restore the modified Quality Profile.

Important: if you are using sonar.cxx.other.rules:

  1. Create a backup of your external rules before installing the cxx plugin.
  2. Install the cxx plugin and restart the SonarQube Server
  3. On new SonarQube servers restore the external rules before your are scaning a project. If you don’t do that issues are closed and reopened in New Code.

Important: Names of configuration properties have been changed

In the cxx plugin, the names of the configuration properties have been changed to match the general naming conventions of SonarQube. The cxx plugin checks if old configuration parameters are used and reports this in the LOG file during the scan. Troubleshooting Configuration describes the details.

other hints:

  • tested and released for SonarQube 7.9 LTS and SonarQube 8.9 LTS with Java 11 (other versions are not supported)
  • The cxx plugin uses a new language key: cxx. The old language key c++ caused problems with its special characters. This leads to the fact that source code and issues are generally considered as New Code after scanning with version 2 the first time.
  • To avoid problems on a SonarQube Server with multiple C++ plugins, the CXX programming language sensor is disabled by default (sonar.cxx.file.suffixes=-). This configuration parameter must therefore be set explicitly now (default was previously .cxx,.cpp,.cc,.c,.hxx,.hpp,.hh,.h).
  • The cxx plugin now uses the name CXX in the SonarQube UI, the previous name C++ (Community) was too long.
  • The configuration settings of the CXX programming language sensor can be found under Administration > CXX.
  • The configuration settings of the CXX report file sensors can be found under Administration > CXX External Analyzers.
  • The C plugin is no longer supported. In the background, only one grammar was used so far and there was only a special treatment for the C++ keywords. The C++ keywords were replaced by a token with underscores (e.g. class => __class__). This can be easily modeled by yourself using a force-include and defines.
  • The report sensors of the cxx plugin are able to read in C and C++ code. Code read in this way is displayed in SonarQube as the CXX programming language (language key=cxx). In addition, the CXX report sensors also support SonarCFamily for C/C++. Here C++ (language key=cpp) and C (language key=c) are supported. You have to decide which plugin you want to use for indexing the source code. In SonarQube, each file extension must be uniquely assigned to one programming language. When operating several C/C++ plugins in parallel, this must be taken into account during configuration (sonar.cxx.file.suffixes). Only one programming language sensor can read in a source file!
  • rules from external tools are deactivated in CXX Default Quality Profile Sonar way
  • names of configuration properties have been changed:
    • sonar.cxx.suffixes.headers => use key sonar.cxx.file.suffixes instead.
      For API detection use sonar.cxx.api.file.suffixes
    • sonar.cxx.suffixes.sources => use key sonar.cxx.file.suffixes instead
    • sonar.cxx.cFilesPatterns => define C++ keywords in an own header file and include it with sonar.cxx.forceIncludes instead
    • sonar.cxx.xunit.xsltURL => use sonar.cxx.xslt instead
    • sonar.cxx.other.xslt.1.inputs => use sonar.cxx.xslt.1.inputs instead
    • sonar.cxx.other.xslt.1.outputs => use sonar.cxx.xslt.1.outputs instead
    • sonar.cxx.other.xslt.1.stylesheet => use sonar.cxx.xslt.1.stylesheet instead
    • sonar.cxx.funccomplexity.threshold => use sonar.cxx.metric.func.complexity.threshold instead
    • sonar.cxx.funcsize.threshold => use sonar.cxx.metric.func.size.threshold instead
    • sonar.cxx.clangsa.reportPath => use sonar.cxx.clangsa.reportPaths instead
    • sonar.cxx.clangtidy.reportPath => use sonar.cxx.clangtidy.reportPaths instead
    • sonar.cxx.coverage.reportPath => use sonar.cxx.bullseye.reportPaths, sonar.cxx.cobertura.reportPaths, sonar.cxx.vscoveragexml.reportPaths or sonar.cxx.ctctxt.reportPaths instead
    • sonar.cxx.cppcheck.reportPath => use sonar.cxx.cppcheck.reportPaths instead
    • sonar.cxx.drmemory.reportPath => use sonar.cxx.drmemory.reportPaths instead
    • sonar.cxx.gcc.reportPath => use sonar.cxx.gcc.reportPaths instead
    • sonar.cxx.msbuild.reportPath => use sonar.cxx.msbuild.reportPaths instead
    • sonar.cxx.nunit.reportsPaths => use sonar.cxx.nunit.reportPaths instead
    • sonar.cxx.other.reportPath => use sonar.cxx.other.reportPaths instead
    • sonar.cxx.pclint.reportPath => use sonar.cxx.pclint.reportPaths instead
    • sonar.cxx.valgrind.reportPath => use sonar.cxx.valgrind.reportPaths instead
    • sonar.cxx.vc.reportPath => use sonar.cxx.vc.reportPaths instead
    • sonar.cxx.vera.reportPath => use sonar.cxx.vera.reportPaths instead
    • sonar.cxx.vstest.reportsPaths => use sonar.cxx.vstest.reportPaths instead
    • sonar.cxx.xunit.reportPath => use sonar.cxx.xunit.reportPaths instead
    • sonar.cxx.xunit.reportsPaths => use sonar.cxx.xunit.reportPaths instead
    • sonar.cxx.clangtidy.charset => use sonar.cxx.clangtidy.encoding instead
    • sonar.cxx.ctctxt.charset => use sonar.cxx.ctctxt.encoding instead
    • sonar.cxx.msbuild.charset => use sonar.cxx.msbuild.encoding instead
    • sonar.cxx.gcc.charset => use sonar.cxx.gcc.encoding instead
    • sonar.cxx.vc.charset => use sonar.cxx.vc.encoding instead
    • sonar.cxx.cpd.ignoreLiterals => use sonar.cxx.metric.cpd.ignoreLiterals instead
    • sonar.cxx.cpd.ignoreIdentifiers => use sonar.cxx.metric.cpd.ignoreIdentifiers instead
  • metrics that are no longer supported (use the tag to filter for issues of a specific tool now): ClangSA issues [CXX-CLANGSA], ClangTidy issues [CXX-CLANG-TIDY], CppCheck issues [CXX-CPPCHECK], DrMemory issues [CXX-DRMEMORY], GCC compiler issues [CXX-COMPILER-GCC], Lines of Code in Functions [CXX-LOC_IN_FUNCTIONS], Other tools issues [CXX-OTHER], PC-Lint issues [CXX-PC-LINT], Rats issues [CXX-RATS], Squid issues [CXX-SQUID], VC compiler issues [CXX-COMPILER-VC], Valgrind issues [CXX-VALGRIND], Vera issues [CXX-VERA++]
  • rules that are no longer supported:
    • ClangSA: alpha.clone.CloneChecker, alpha.core.BoolAssignment, alpha.core.CallAndMessageUnInitRefArg, alpha.core.CastSize, alpha.core.CastToStruct, alpha.core.Conversion, alpha.core.DynamicTypeChecker, alpha.core.FixedAddr, alpha.core.IdenticalExpr, alpha.core.PointerArithm, alpha.core.PointerSub, alpha.core.SizeofPtr, alpha.core.TestAfterDivZero, alpha.cplusplus.IteratorRange, alpha.cplusplus.MisusedMovedObject, alpha.deadcode.UnreachableCode, alpha.osx.cocoa.DirectIvarAssignment, alpha.osx.cocoa.DirectIvarAssignmentForAnnotatedFunctions, alpha.osx.cocoa.InstanceVariableInvalidation, alpha.osx.cocoa.MissingInvalidationMethod, alpha.osx.cocoa.localizability.PluralMisuseChecker, alpha.security.ArrayBound, alpha.security.ArrayBoundV2, alpha.security.MallocOverflow, alpha.security.ReturnPtrRange, alpha.security.taint.TaintPropagation, alpha.unix.BlockInCriticalSection, alpha.unix.Chroot, alpha.unix.PthreadLock, alpha.unix.SimpleStream, alpha.unix.Stream, alpha.unix.cstring.BufferOverlap, alpha.unix.cstring.NotNullTerminated, alpha.unix.cstring.OutOfBounds, apiModeling.google.GTest, core.DynamicTypePropagation, core.builtin.BuiltinFunctions, core.builtin.NoReturnFunctions, cplusplus.SelfAssignment, llvm.Conventions, unix.StdCLibraryFunctions
    • compiler-vc: C26412, C26423, C26424, C26470, C28101, C28110, C28111, C28114, C28120, C28121, C28122, C28123, C28124, C28126, C28127, C28128, C28129, C28131, C28132, C28133, C28134, C28135, C28141, C28143, C28144, C28145, C28146, C28147, C28150, C28151, C28152, C28153, C28156, C28157, C28158, C28161, C28162, C28165, C28166, C28167, C28168, C28169, C28170, C28171, C28172, C28173, C28175, C28176, C28260, C28266, C28601, C28602, C28604, C28615, C28616, C28617, C28623, C28624, C28625, C28636, C28637, C28638, C28639, C28640, C28645, C28648, C28649, C28650, C28714, C28715, C28716, C28717, C28719, C28720, C28721, C28726, C28727, C28730, C28735, C28736, C28750, C28751, C4203, C4231, C4303, C4317, C4318, C4341, C4345, C4347, C4351, C4422, C4426, C4428, C4432, C4433, C4474, C4475, C4476, C4478, C4480, C4482, C4509, C4519, C4520, C4539, C4748, C4774, C4775, C4776, C4777, C4778, C4801, C4815, C4826, C4832, C4836, C4837, C4980, C6057, C6202, C6203, C6204, C6209, C6309, C6327, C6507, C6512, C6521, C6523, C6526, C6535
    • cppcheck: class_X_Y, complexPatternError, cppcheckError, dangerousUsageStrtol, doubleCloseDir, duplicateIf, exceptThrowInAttributeNoThrowFunction, exceptThrowInDeclspecNoThrowFunction, exceptThrowInNoThrowFunction, exceptThrowInNoexecptFunction, ftimeCalled, gmtimeCalled, invalidScanfArgType, leakconfiguration, missingPercentCharacter, obsoleteFunctionasctime, obsoleteFunctionsasctime, obsoleteFunctionsgets, possibleReadlinkBufferOverrun, redundantNextPrevious, simplePatternError, stlBoundries, suspiciousEqualityComparison, syntaxError, tooBigSleepTime, udivError, unknownPattern, unmatchedSuppression, writeOutsideBufferSize, wrongcctypecall
    • cxx: MissingIncludeFile

Known Issues

For an up to date list of known issues see the issue tracker.

  • only tested with Java 11
    • Message "The plugin [cxx] does not support Java 1.8.0, UnsupportedClassVersionError". To solve this download OpenJDK 11 und unzip it (http://jdk.java.net/archive/). Point with the JAVA_HOME environment variable to the Java 11 location.
  • In SonarQube, each file extension must be uniquely assigned to one programming language. When operating several C/C++ plugins in parallel, this must be taken into account during configuration. To avoid problems on a server with multiple C++ plugins, the CXX programming language sensor is disabled by default.
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable rules for external tools per default.
  • Message: "C++ cannot be analyzed with current SonarQube edition. Please consider upgrading...". SonarQube issues this message when an input file with the file extension .c, .cc, .cpp, .cxx or .c++ is read in the Community Edition. Select "Dismiss permanently" to continue without the message.
  • cxx-sslr-toolkit-x.y.z.jar is not a plugin. Do not copy it to the plugins folder. If the JAR file does not contain a SonarQube plugin, the following error message appears in the LOG file when the server is started: ERROR Web server startup failed java.lang.NullPointerException: Plugin key is missing from manifest.


Upgrade to 1.3.2 and 1.3.3

  • tested and released for SonarQube 6.7 LTS with Java 8 and SonarQube 7.9 LTS with Java 11
  • rules from external tools are deactivated in cxx plugin default profile
  • customRules no more supported
  • cxx-lint tool no more supported
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific (different) file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • Set sonar.cxx.cFilesPatterns in the C plugin configuration only (but not in the cxx plugin configuration).
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only

Upgrade to 1.3.1

  • tested and released for SonarQube 6.7 LTS with Java 8 and SonarQube 7.9 LTS with Java 11
  • rules from external tools are deactivated in cxx plugin default profile
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific (different) file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • Set sonar.cxx.cFilesPatterns in the C plugin configuration only (but not in the cxx plugin configuration).
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only

Upgrade to 1.3.0

  • Compatible with SonarQube 6.7 LTS, 7.0, 7.1, 7.2, 7.3, 7.4, 7.5, 7.6, 7.7 and 7.8
  • Java Runtime Environment 8 is supported (not tested with Java 9, 10 and 11)
  • static code analysis checks are removed:
    • BooleanEqualityComparisonCheck, CollapsibleIfCandidateCheck, CommentedCodeCheck, HardcodedAccountCheck, HardcodedIpCheck, MagicNumberCheck, MissingCurlyBracesCheck, NestedStatementsCheck, ReservedNamesCheck, SafetyTagCheck, StringLiteralDuplicatedCheck, SwitchLastCaseIsDefaultCheck, UnnamedNamespaceInHeaderCheck, UseCorrectIncludeCheck, UseCorrectTypeCheck, UselessParenthesesCheck, UsingNamespaceInHeaderCheck
    • use external tools like CppCheck, Clang, .... instead
  • cxx-lint tool is no more part of cxx plugin
  • project's duplication density value will likely rise with SQ 7.8 (SONAR-12188)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific (different) file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • Set sonar.cxx.cFilesPatterns in the C plugin configuration only (but not in the cxx plugin configuration).
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only

Upgrade to 1.2.2

  • Compatible with SonarQube 6.7 LTS, 7.0, 7.1, 7.2, 7.3, 7.4, 7.5 and 7.6
  • Java Runtime Environment 8 is supported (Java 9 is not supported).
  • Optimized AST: some nodes are removed from AST. Please verify user defined checks and XPath expressions if they are still working.
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific (different) file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • Set sonar.cxx.cFilesPatterns in the C plugin configuration only (but not in the cxx plugin configuration).
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only
    • sonar.cxx.scanOnlySpecifiedSources is no more supported. There were conflicts with sonar.sources and sonar.tests.

Upgrade to 1.2.1

  • Compatible with SonarQube 6.7 LTS, 7.0, 7.1, 7.2, 7.3, 7.4 and 7.5
  • Java Runtime Environment 8 is supported (Java 9 is not supported).
  • duplicated_lines_density values are different with SQ 7.5
  • Cognitive Complexity support. There are two known limitations:
    • recursion is not handled
    • cognitive complexity per file is not available (Metrics/Coverage/Cognitive Complexity)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific (different) file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • Set sonar.cxx.cFilesPatterns in the C plugin configuration only (but not in the cxx plugin configuration).
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only
    • sonar.cxx.scanOnlySpecifiedSources is no more supported. There were conflicts with sonar.sources and sonar.tests.

Upgrade to 1.2.0

  • Compatible with SonarQube 6.7 LTS, 7.0, 7.1, 7.2, 7.3 and 7.4
  • Java Runtime Environment 8 is supported (Java 9 is not supported).
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable all rules per default.
  • GCC and MSVC compiler sensor can be used at the same time now
    • BREAKING CHANGE : sonar.cxx.compiler settings are no more supported!
      • use sonar.cxx.vc to read MSVC reports
      • use sonar.cxx.gcc to read GCC reports
      • use sonar.cxx.msbuild to read includes and defines from MSBuild log file
  • Complexity metrics are performed on original source code now
    • In the past we were first preprocessing the code and were calculating the complexity metrics on base of the preprocessed code. This could lead to confusing metric numbers because macro code is counted multiple times and could also be from external libraries. Generated code (among others macro expansions) doesn't affect the calculation of cognitive / cyclomatic complexity now. This can lead to different but easier to understand metrics.
  • Setting sonar.cxx.missingIncludeWarnings is no more available. Turn debug info on to get information.
  • The naming of the following metrics have been changed:
    • perc_complex_functions -> CXX-PERC_COMPLEX_FUNCTIONS
    • loc_in_complex_functions -> LOC_IN_COMPLEX_FUNCTIONS
    • perc_loc_in_complex_functions -> CXX-PERC_LOC_IN_COMPLEX_FUNCTIONS
    • big_functions -> CXX-BIG_FUNCTIONS
    • loc_in_big_functions -> CXX-LOC_IN_BIG_FUNCTIONS
    • perc_big_functions -> CXX-PERC_BIG_FUNCTIONS
    • perc_loc_in_big_functions -> CXX-PERC_LOC_IN_BIG_FUNCTIONS
    • loc_in_functions -> CXX-LOC_IN_FUNCTIONS
    • To keep the old metric values run in your database before upgrading to 1.2.x: update dbo.metrics set name = upper('CXX-' + name) where name in ('complex_functions', 'perc_complex_functions', 'big_functions', 'perc_big_functions', 'loc_in_complex_functions', 'perc_loc_in_complex_functions', 'loc_in_big_functions', 'perc_loc_in_big_functions', 'loc_in_functions')
  • Cognitive Complexity support. There are two known limitations:
    • recursion is not handled
    • cognitive complexity per file is not available (Metrics/Coverage/Cognitive Complexity)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific (different) file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • Set sonar.cxx.cFilesPatterns in the C plugin configuration only (but not in the cxx plugin configuration).
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only
    • sonar.cxx.scanOnlySpecifiedSources is no more supported. There were conflicts with sonar.sources and sonar.tests.

Upgrade to 1.1.0

  • Compatible with SonarQube 6.7 LTS, 7.0, 7.1 and 7.2
  • Java Runtime Environment 8 is supported (Java 9 is not supported).
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable all rules per default.
  • Cognitive Complexity support. There are two known limitations:
    • recursion is not handled
    • cognitive complexity per file is not available (Metrics/Coverage/Cognitive Complexity)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • sonar.cxx.cFilesPatterns should be set in the C plugin configuration but not in the cxx plugin configuration.
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only
    • sonar.cxx.scanOnlySpecifiedSources is no more supported. There were conflicts with sonar.sources and sonar.tests.

Upgrade to 1.0.0

  • Compatible with SonarQube 6.7 LTS, 7.0 and 7.1
  • Java Runtime Environment 8 is supported (Java 9 is not support).
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable all rules per default.
  • Cognitive Complexity support. There are two known limitations:
    • recursion is not handled
    • cognitive complexity per file is not available (Metrics/Coverage/Cognitive Complexity)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • sonar.cxx.cFilesPatterns should be set in the C plugin configuration but not in the cxx plugin configuration.
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only
    • sonar.cxx.scanOnlySpecifiedSources is no more supported. There were conflicts with sonar.sources and sonar.tests.

Upgrade to 0.9.9

  • Compatible with SonarQube 6.7 LTS
  • Java Runtime Environment 8 is supported (Java 9 is not support).
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable all rules per default.
  • There are some changes in the SQ core API, starting with SQ 6.2:
    • The property sonar.cxx.forceZeroCoverage is no more supported. There is now a SQ core support basing on EXECUTABLE_LINES_DATA.
    • Calculation of coverage values is slightly different now (coverage is typically a little bit higher).
  • sonar.cxx.coverage.itReportPath and sonar.cxx.coverage.overallReportPath are no more supported by the SQ core. There is no replacement available.
    • Documentation metrics are no more supported by SQ. We added cxx plugin specific metrics for PUBLIC_API, PUBLIC_DOCUMENTED_API_DENSITY, PUBLIC_UNDOCUMENTED_API as replacement. History of SQ values is lost.
    • the following metrics are no more supported: FILE_COMPLEXITY_DISTRIBUTION, COMPLEXITY_IN_FUNCTIONS, COMPLEXITY_IN_CLASSES and FUNCTION_COMPLEXITY_DISTRIBUTION
  • Cognitive Complexity support. There are two known limitations:
    • recursion is not handled
    • cognitive complexity per file is not available (Metrics/Coverage/Cognitive Complexity)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • sonar.cxx.cFilesPatterns should be set in the C plugin configuration but not in the cxx plugin configuration.
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only

Upgrade to 0.9.8

  • Compatible with SonarQube 5.6 LTS, 6.0, 6.1, 6.2, 6.3, 6.4, 6.5, 6.6, 6.7 LTS
  • Java Runtime Environment 8 is supported (Java 9 is not support).
  • Ensure that a rule is enabled if you get no results. In new SQ versions the default profile is read-only. The cxx plugin does not enable all rules per default.
  • There are some changes in the SQ core API, starting with SQ 6.2:
    • The property sonar.cxx.forceZeroCoverage is no more supported. There is now a SQ core support basing on EXECUTABLE_LINES_DATA.
    • Calculation of coverage values is slightly different now (coverage is typically a little bit higher).
    • sonar.cxx.coverage.itReportPath and sonar.cxx.coverage.overallReportPath are no more supported by the SQ core. There is no replacement available.
    • Documentation metrics are no more supported by SQ. We added cxx plugin specific metrics for PUBLIC_API, PUBLIC_DOCUMENTED_API_DENSITY, PUBLIC_UNDOCUMENTED_API as replacement. History of SQ values is lost.
  • Cognitive Complexity support. There are two known limitations:
    • recursion is not handled
    • cognitive complexity per file is not available (Metrics/Coverage/Cognitive Complexity)
  • Usage of C plugin in parallel.
    • Please keep in mind that the C plugin is still experimental.
    • You can use all CXX configuration properties also for the C plugin: use sonar.c.xxx instead of sonar.cxx.xxx
    • You have to set specific file extensions in sonar.cxx.suffixes.sources and sonar.c.suffixes.sources.
    • sonar.cxx.cFilesPatterns should be set in the C plugin configuration but not in the cxx plugin configuration.
  • Json compilation database support sonar.cxx.jsonCompilationDatabase is also experimental only

Upgrade to 0.9.7

  • Compatible with SonarQube 5.6.x, 6.0, 6.1 and 6.2
  • Java Runtime Environment 8 is supported (Java 9 is not support).
  • Improved report handling: there is a tolerant and a strict mode now. In tolerant mode analysis continue in case of errors in a report file. In strict mode an error in a report file will stop the analysis (sonar.cxx.errorRecoveryEnabled). In versions before this one behaviour was sometimes strict and sometimes tolerant.
  • The default value of sonar.cxx.errorRecoveryEnabled is True now. To go back to old behaviour set the value to False.
  • sonar.cxx.forceZeroCoverage: better detection of executable lines. Resulting coverage can be slightly different.
  • Improved CPD algorithm with additional configuration settings sonar.cxx.cpd.ignoreLiterals and sonar.cxx.cpd.ignoreIdentifiers. To get same numbers as before set both to False.
  • Detailed mode from test metrics is no more supported with SQ 5.6 API (sonar.cxx.xunit.provideDetails).
  • Computation of package/file tangle metrics no more supported with SQ 5.6 API.
  • Unit Test Success (%) is no more supported with SQ 5.6 API.
  • With SQ 6.2 overall and integration coverage metrics are no more supported.
  • remove deprecated SQALE quality model; sonar.cxx.other.sqales is no more supported
  • support of new SonarQube quality model; update the format of the rule files

Upgrade to 0.9.6

  • Compatible with SonarQube 5.6.x
  • Java Runtime Environment 8 is supported (end of Java 7 support).
  • remove deprecated SQALE quality model; sonar.cxx.other.sqales is no more supported
  • support of new SonarQube quality model; update the format of the rule files

Upgrade to 0.9.5

  • Compatible with SonarQube 4.5.2+, 5.0.x, 5.1.x, 5.3.x, 5.4.x and 5.5.x
  • Java Runtime Environment 7 and 8 are supported. JRE 8 is recommended because of higher system performance.
  • Undocumented public API detection: documentation for methods marked with "override" is optional now. This results typically in less documentation issues.
  • Improved calculation of metric COMPLEXITY_IN_CLASSES. Values for COMPLEXITY_IN_CLASSES can be different.
  • TooManyLinesOfCodeInFunctionCheck: improved LOC counting, Values can be different.

Upgrade to 0.9.4

  • Compatible with SonarQube 4.5.2+, 5.0.x and 5.1.x
  • Java Runtime Environment 7 and 8 are supported. JRE 8 is recommended because of higher system performance.
  • Default values for reportPath values has been removed to get meaningful error messages. In case you were using the defaults you have to explicit define them in the sonar-project.properties file now.
  • forceZeroCoverage: Depends on which key (sonar.cxx.coverage.reportPath, sonar.cxx.coverage.itReportPath, sonar.cxx.coverage.overallReportPath) is defined in the sonar-project.properties file now. Defining forceZeroCoverage alone will no more work.
  • It is now possible to define Sqale characteristics for external rules (other) but there are still no predefined values.

Upgrade to 0.9.3

  • Compatible with SonarQube 4.5.2+, 5.0.x and 5.1.x
  • Java Runtime Environment 7 and 8 are supported. JRE 8 is recommended because of higher system performance.
  • External rules (other) does not support Sqale characteristics.
  • Metric COMMENT_BLANK_LINES is deprecated and no more supported (SONAR-3768).
  • Property sonar.cxx.coverage.forceZeroCoverage supports line, integration and overall coverage now.
  • Since SonarQube 5.0, there is a built-in support for SCM information on source files. In case you don't want to use it set sonar.scm.disabled=true to your project configuration to disable SCM support.
  • Support of new syntax highlighter API (SONAR-3893): Formatting of source code is different.
  • Cppcheck/inconclusive messages: there is [inconclusive] at the beginning of the message now.
  • cxx plugin rules visible under 'c++ SonarQube'. Some of the rules has changed rule keys. Especially template rules are not activated by default. Please check listed rules below if they have the same state in your profile as before:
    • FileCyclomaticComplexity => FileComplexity
    • InvalidFileEncoding => FileEncoding
    • UseFileHeader => FileHeader
    • NotAllowedFixMeTag => FixmeTagPresence
    • FunctionCyclomaticComplexity => FunctionComplexity
    • NoHardcodedAccount => HardcodedAccount
    • NoHardcodedIp => HardcodedIp
    • IndentationCheck => Indentation
    • MissingInclude => MissingIncludeFile
    • NewLineAtEOF => MissingNewLineAtEndOfFile
    • ReservedNamesCheck => ReservedNames
    • SafetyTagCheck => SafetyTag
    • SwitchLastCaseIsDefaultCheck => SwitchLastCaseIsDefault
    • NoTabCharacter => TabCharacter
    • NotAllowedToDoTag => TodoTagPresence

Upgrade to 0.9.2

  • Compatible with SonarQube 4.5
  • Coverage: New property sonar.cxx.coverage.forceZeroCoverage set coverage for source files without coverage report to zero. For V0.9.1 compatibility set value to 'false'.
  • Unit Tests: New property sonar.cxx.xunit.provideDetails. To get detailed unit test information set property to 'true'. This is also the V0.9.1 compatibility value. SonarQube does not support 'virtual files' anymore. In case your report files contain 'filename' tags they must match with 'physical files'.

Upgrade to 0.9.1

  • Compatible with SonarQube 3.7 to 4.2.
  • Configuration setting sonar.cxx.cppncss.reportPath is no longer supported.
  • Rename configuration setting sonar.cxx.externalrules.reportPath to sonar.cxx.other.reportPath
  • Rename configuration setting sonar.cxx.include_directories to sonar.cxx.includeDirectories
  • Upgrade quality profiles: Backup the quality profile as XML. Search and replace in old quality profile <repositoryKey>cxxexternal</repositoryKey> with <repositoryKey>other</repositoryKey>. Restore it after this replacement again.
  • Folder ..\Sonar\sonar-x.y.z\extensions\rules is no longer supported. Add file content via settings in the SonarQube UI to sonar.cxx.other.rules in the C++ community backend settings instead.
  • Lines of Code (LoC) are counted differentially compared to V0.2: Macro definitions are no more counted as LoC. Leads to changes in LoC and derived metrics.
Clone this wiki locally