Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to verify webhooks are being received and processed correctly

David Keaveny
Contributor
April 13, 2025

I have an on-premise installation of SonarQube that I want to receive code analysis webhooks from. I followed the Atlassian instructions to set up an organisation-level webhook in SonarQube and pasted in the generated webhook URL that Compass created for me. I then added a link to the SonarQube project to the Dashboard links of my Compass component. Finally, I made a code change on my GitHub-hosted repo; SonarQube ran its analysis task, and I can see that it published a successful analysis result to Compass, receiving a 202 Accepted response code.

However, the Sonar Quality Gate scorecard that I added to my project is still reporting a failing status, and if I click on the scorecard, it asks me to connect the metric to a data source.

From SonarQube's point of view, everything has gone correctly; how can I identify where my metrics have disappeared to in Compass?

1 answer

1 accepted

4 votes
Answer accepted
David Keaveny
Contributor
April 13, 2025

Ugh, never mind. I finished typing this question in, went back to my project and saw that there was a different metric receiving the data from the webhook; I changed my scorecard to use the correct metric (quality-gate-conditions-passing) and now everything is working as expected.

The link to the SonarQube project needs to be added to the Projects section of Links; SonarQube itself needs to be set up as an incoming webhook, which feeds the "Quality gate conditions passing" metric, which is displayed through the "Sonar Quality Gate" scorecard. So, a few moving parts to connect up, but hopefully this gives enough information to point you in the right direction.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events