Sonarqube Version: 7.9.1 Developer Edition - latest version
Java: Redhat OpenJDK 11
GitHub Enterprise version 2.15
Sonar scanner version: 3.3
The scan and analysis is happening as expected. The only thing we are seeing is the decoration of the PR is not happening at all. When Sonarqube was in Trace log we saw the below log entries:
2019.07.22 20:11:55 DEBUG ce[AWwbGOeqf_exK80zuTOH][c.s.C.A.C.A.A.D] GET response did not have expected HTTP code (was 401): {"message":"'Issued at' claim ('iat') must be an Integer representing the time that the assertion was issued","documentation_url":"https://developer.github.com/enterprise/2.15/v3"}
2019.07.22 20:11:55 TRACE ce[AWwbGOeqf_exK80zuTOH][sql] time=1ms | sql=insert into ce_task_message ( uuid, task_uuid, message, created_at ) values ( ?, ?, ?, ? ) | params=AWwbGPM1pulh-2K9ftK1, AWwbGOeqf_exK80zuTOH, Pull request decoration did not happen. Please install SonarQube Github application on the repository's organization or user., 1563822715701
Remediation steps tried:
- Re-install GitHub Application on Organisation - no change
- Regenerate Private key - no change
- Enter invalid Private key - error caused with invalid key (putting it back same no decoration but no error)
- Re-configured Pull Request settings and re setup application properties - different errors but no success on decorations
What have we set in SonarQube Administration â Pull Request tab
- sonar.pullrequest.provider = GitHub
- sonar.pullrequest.github.endpoint = https://our-company-url/api/v3
- sonar.alm.github.app.name = SonarQubePRChecks
- sonar.alm.github.app.id = XX
- sonar.alm.github.app.privateKeyContent.secured = Key created by SonarQube app on GitHub
Sonar.properties are as follows:
- sonar.projectKey=organisation:repo-name
- sonar.projectName=repo-name
- sonar.sourceEncoding=UTF-8
- sonar.sources=pom.xml, src/main
- sonar.projectVersion=x.y.0-PRZZ
- sonar.projectBaseDir=jenkins-folder-patg
- sonar.tests=src/test/java
- sonar.java.binaries=target/classes/**
- sonar.pullrequest.branch=branch-name
- sonar.pullrequest.key=123 (github pull request number
- sonar.pullrequest.base=master
- sonar.pullrequest.github.repository=orgainsation/repo-name
- sonar.verbose=true
- sonar.issuesReport.console.enable=true