Negative values for issues in sonarqube webhook payload

metrics
fix_the_leak
webhooks

(Naveen Arora) #1

Hi
I have configured Webhook for Sonarqube project so that whenever a sonar scan run, we get the project scan results through webhook. Sometimes the SonarQube webhook payload has negative values for critical issues, major issues etc…
Would like to understand in what cases we get those negative values and how to interpret those negative values.

Regards
Naveen


(G Ann Campbell) #2

Hi Naveen,

Could you share an example payload?

Ann


(Badhra) #3

Hi Ann,

Naveen and I are working on this. Here is the webhook payload from sonarqube.Sonarqube webhook payload.txt (1.6 KB)

Regards,
Badhra


(Badhra) #4

The critical violations has -3 value and blocker violations has -1 value.


(Nicolas Bontoux) #5

Based on the payload you’ve shared those conditions are checked over the Leak Period ("onLeakPeriod":true). Did you check (e.g. via the UI) if the negative simply doesn’t correspond to a diminishing number of issues ?