port-labs / ocean

🌊 Ocean 🌊 is an innovative solution developed by Port to seamlessly integrate various third-party systems with our developer portal product, empowering engineers to effortlessly prioritize key features and streamline the integration process.
https://ocean.getport.io
Apache License 2.0
120 stars 56 forks source link

[Enhancement] [Integration] [Sonar Qube] - Update raw data and default blueprints #80

Closed danielsinai closed 1 year ago

danielsinai commented 1 year ago

Motivation

As for today, the Sonar Qube integration initiated with data that lacks the main features of SonarQube and people struggle to gain real value from it from the first installation.

For improving that it would be best to enrich the Raw Data that the SonarQube integration brings by addressing more SonarQube APIS.

Moreover, to reduce the time, people gain value from the integration we would like to change the default resources of the integration to include more properties.

Proposed Changes

In order to achieve the above goals, we need to change completely the blueprints and data that sonarQube brings out-of-the-box.

Here is my suggestion to blueprints:

Blueprints ```json [ { "identifier": "sonarQubeProject", "title": "SonarQube Project", "icon": "sonarqube", "schema": { "properties": { "organization": { "type": "string", "title": "Organization", "icon": "TwoUsers" }, "link": { "type": "string", "format": "url", "title": "Link", "icon": "Link" }, "lastAnalysisStatus": { "type": "string", "title": "Last Analysis Status", "enum": [ "PASSED", "FAILED" ], "enumColors": { "PASSED": "green", "FAILED": "red" } }, "lastAnalysisDate": { "type": "string", "format": "date-time", "icon": "Clock" }, "numberOfBugs": { "type": "number", "title": "Number Of Bugs" }, "numberOfCodeSmells": { "type": "number", "title": "Number Of CodeSmells" }, "numberOfVulnerabilities": { "type": "number", "title": "Number Of Vulnerabilities" }, "numberOfHotSpots": { "type": "number", "title": "Number Of HotSpots" }, "numberOfDuplications": { "type": "number", "title": "Number Of Duplications" }, "coverage": { "type": "number", "title": "Coverage" }, "mainBranch": { "type": "string", "icon": "Git", "title": "Main Branch" }, "tags": { "type": "array", "title": "Tags" } }, "required": [] }, "mirrorProperties": {}, "calculationProperties": {}, "relations": {} }, { "identifier": "sonarQubeAnalysis", "title": "SonarQube Analysis", "icon": "sonarqube", "schema": { "properties": { "branch": { "type": "string", "title": "Branch", "icon": "GitVersion" }, "fixedIssues": { "type": "number", "title": "Fixed Issues" }, "newIssues": { "type": "number", "title": "New Issues" }, "coverage": { "title": "Coverage", "type": "number" }, "duplications": { "type": "number", "title": "Duplications" }, "createdAt": { "type": "string", "format": "date-time" } } }, "relations": { "sonarQubeProject": { "target": "sonarQubeProject", "required": false, "title": "SonarQube Project", "many": false } } }, { "identifier": "sonarQubeIssue", "title": "SonarQube Issue", "icon": "sonarqube", "schema": { "properties": { "type": { "type": "string", "title": "Type", "enum": [ "CODE_SMELL", "BUG", "VULNERABILITY" ] }, "severity": { "type": "string", "title": "Severity", "enum": [ "MAJOR", "INFO", "MINOR", "CRITICAL", "BLOCKER" ], "enumColors": { "MAJOR": "orange", "INFO": "green", "CRITICAL": "red", "BLOCKER": "red", "MINOR": "yellow" } }, "link": { "type": "string", "format": "url", "icon": "Link", "title": "Link" }, "status": { "type": "string", "title": "Status", "enum": [ "OPEN", "CLOSED", "RESOLVED", "REOPENED", "CONFIRMED" ] }, "assignees": { "title": "Assignees", "type": "array", "icon": "TwoUsers", "items": { "type": "string", "format": "user" } }, "tags": { "type": "array", "title": "Tags" } } }, "relations": { "sonarQubeProject": { "target": "sonarQubeProject", "required": false, "title": "SonarQube Project", "many": false } } } ] ```

image

Are you willing to submit a PR?

danielsinai commented 1 year ago

Fixed by #103 thanks @PeyGis