Operating system: Microsoft Windows Server 2012 R2
SonarScanner-v4.2.0.1873
Problem statement: Stash/Bitbucket notification skipped. The Pull Request decoration is not happening. It is not clear which property is missing.
Scanner logs: Last few lines….
10:18:25.702 DEBUG: **'Stash/Bitbucket notification' skipped because one of the required properties is missing'**
10:18:25.704 DEBUG: Post-jobs :
10:18:26.033 INFO: Analysis total time: 16.254 s
10:18:26.071 INFO: ------------------------------------------------------------------------
10:18:26.072 INFO: EXECUTION SUCCESS
10:18:26.072 INFO: ------------------------------------------------------------------------
10:18:26.072 INFO: Total time: 19.953s
10:18:26.174 INFO: Final Memory: 17M/108M
10:18:26.174 INFO: ------------------------------------------------------------------------
Steps to reproduce
Sonar properties:
Global SonarQube=>Administration=>General Settings=>Pull Requests=>
sonar.pullrequest.provider = Bitbucket Server
sonar.pullrequest.bitbucketserver.serverUrl = <our bitbucket server URL>
sonar.pullrequest.bitbucketserver.token.secured = <a valid personal access token from Bitbucket server that has write access to the repository>
This message refers to the mibexsoftware/sonar-bitbucket-plugin, not the native integration with Bitbucket Server provided by SonarQube v7.9 that is described in the documentation on Pull Request Analysis. Let’s ignore that for now.
Does a Pull Request show up when you browse your SonarQube Project?
What do you see when you open the PR link from SonarQube? You should see something like this that you can click on for more details.
It doesn’t look like the PR raised any issues (at least from what I can see of the screenshot shared), so I wouldn’t expect there to be any in-line issues on the Bitbucket side.
It looks like we’re dealing with quite some old PR analyses (the PR you shared a screenshot of is from April 3rd, while the SonarQube analysis was done on… March 26th?)
How about a fresh PR build/analysis?
If that doesn’t help, I’d recommend…
raising your log level to TRACE level (Global Administration > System > Log Level),
triggere an analysis you expect to result in PR Decoration and wait for the PR to be visible in SonarQube
After much investigation we found that we were using all the properties correctly yet the decoration was not happening. However, due to an unconnected issue we had to restart our Bitbucket Server’s reverse proxy that has resolved the PR decoration issue too. Guess the proxy was blocking the passage of the decorator.
Thank you very much for your time on this issue, Colin.