SonarCloud / SonarQube Cloud
Qualitäts- und Security-Domäne für Codeanalyse, Quality Gates und Berechtigungen
SonarCloud misst Codequalität und Security-Befunde. Backstage zeigt die Ergebnisse servicebezogen, AccessHub verwaltet Rollen und Analysetoken.
Projects
47
Gates Passed
38 / 47
Critical Issues
3
Ø Coverage
76%
Integrationsarchitektur
Rollenpakete
| Role | Beschreibung | Genehmiger |
|---|---|---|
| SONAR_ORG_VIEWER | Lesende Sicht auf Qualitätsdaten | Team Owner |
| SONAR_PROJECT_ADMIN | Administration eines SonarCloud-Projekts | Service Owner + Plattform |
| SONAR_EXECUTE_ANALYSIS | Analyse über Token/Pipeline ausführen | Service Owner |
| SONAR_QUALITY_GATE_ADMIN | Pflege von Quality Gates | Security + Plattform |
| SONAR_QUALITY_PROFILE_ADMIN | Pflege von Qualitätsprofilen | Security + Plattform |
| SONAR_ORG_ADMIN | Organisationsweite Administration | Restriktiv, 4-Augen |
Quality Gate Dokumentation
Ist ein Quality Gate vorhanden?
Link zum Projekt und Gate-Status
Ist das Gate bestanden?
Aktueller Status, Analysedatum
Wenn nicht bestanden: warum?
Dokumentierte Ausnahme oder Risikoeintrag
Wer ist verantwortlich?
Service Owner und Security Owner
Bis wann wird behoben?
Zieltermin oder nächster Review
Quality Profiles
| Profile | Language | Rules | Mandatory | Enforced on |
|---|---|---|---|---|
| HERMOS Java - Strict | Java | 412 | fis_*, shared_* | |
| HERMOS TypeScript - Strict | TypeScript | 298 | fis_portal_*, tnt_*_web | |
| HERMOS C# - Strict | C# | 356 | tnt_orders_*, fise_* | |
| HERMOS Python - Default | Python | 187 | Data Science Projects |
Webhooks & Aktualisierung & Events
SonarCloud-Webhooks werden bevorzugt über einen AccessHub- oder Plattform-Endpunkt empfangen, dort HMAC-validiert, einer Backstage-Entity zugeordnet und lösen Read-Model-Updates und Notifications aus.
CeEvent (Background Task)· Analyse abgeschlossenConsumer: AccessHub + Backstage
Action: Quality-Gate-Status an CMDB, Backstage-Card invalidieren, Approval-Policies prüfen
QualityGateEvent· Gate-Status wechseltConsumer: AccessHub
Action: Prod-Deploy-Request automatisch blockieren wenn Gate failed (SoD-Regel sod-prod-sonar-gate)
IssueEvent (Security Hotspot)· Neue Critical/Blocker VulnerabilityConsumer: Security Evidence
Action: Finding mit CWE, CVSS, Owner anlegen, SLA-Clock starten, Benachrichtigung an Service Owner
REST API Nutzung
| Method | Path | Verwendung | Rate-Limit |
|---|---|---|---|
| GET | /api/projects/search | Projekt-Inventar für Backstage Catalog Sync | 60/min |
| GET | /api/measures/component | Quality Gate, Coverage, Tech Debt pro Component | 60/min |
| GET | /api/qualitygates/project_status | Gate-Status für PR-Decoration und AccessHub Prod-Gate | 60/min |
| GET | /api/issues/search | Findings in Security Evidence Store importieren | 30/min |
| GET | /api/hotspots/search | Security Hotspots je Projekt | 30/min |
| POST | /api/qualityprofiles/activate_rule | Policy-Sync: HERMOS-Standardregeln aktivieren | admin only |
| POST | /api/webhooks/create | Webhook-Registrierung pro Projekt | admin only |
Token Scopes & Rotation
| Scope | Used by | Holder | Expiry |
|---|---|---|---|
| Execute Analysis | CI/CD Pipelines | Pipeline Service Principal | 90 Tage · Auto-Rotation |
| Browse Project | Backstage Read Plugin | Backstage SA | 180 Tage |
| Administer Project | AccessHub Admin-Operations | AccessHub Platform Team | 90 Tage · 4-Augen-Rotation |
| Administer Quality Profiles | Policy-Sync | Security Engineering | 180 Tage |
PR & Branch Integrationen
Azure DevOps · PR Decoration
Kommentare in Pull Requests mit Gate-Status, Coverage-Delta, neuen Issues
Azure DevOps · Branch Analysis
Short-lived Branches werden gegen den Base-Branch analysiert
GitHub (Atlassian Mirror) · Status Check
Quality Gate als required check
Projects
| Project Key | Quality Gate | Bugs | Vulns | Coverage | Hotspots | Debt | New Lines |
|---|---|---|---|---|---|---|---|
| fis_invoice_api | passed | 0 | 0 | 82% | 2 | 1d 4h | 840 |
| fis_portal_web | failed | 3 | 1 | 64% | 5 | 4d 2h | 1250 |
| tnt_orders_api | passed | 1 | 0 | 78% | 1 | 0d 6h | 320 |
| shared_auth_lib | warn | 0 | 2 | 91% | 0 | 0d 2h | 95 |