Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: SonarCloud coverage #26

Merged
merged 15 commits into from
Oct 18, 2024
Merged

ci: SonarCloud coverage #26

merged 15 commits into from
Oct 18, 2024

Conversation

pflynn-virtru
Copy link
Member

@pflynn-virtru pflynn-virtru commented Oct 16, 2024

Introduced a new SonarCloud scan step in the GitHub Actions workflow to enhance code quality checks. Updated pom.xml to include SonarCloud configuration properties and reorganized Jacoco plugins under a new coverage profile.

DSP-120

Introduced a new SonarCloud scan step in the GitHub Actions workflow to enhance code quality checks. Updated `pom.xml` to include SonarCloud configuration properties and reorganized Jacoco plugins under a new coverage profile.
@pflynn-virtru pflynn-virtru requested review from a team as code owners October 16, 2024 16:25
Upgraded the io.opentdf.platform:sdk dependency to version 0.7.3. Removed redundant server entries and repository configurations for 'opentdf' in settings.xml and pom.xml respectively to streamline the configuration.
Transferred SonarQube configuration from global properties section to the coverage profile in pom.xml. Added JaCoCo report generation during the test phase in both parent and processor-specific POMs.
This commit adds a `dataFile` configuration to the JaCoCo plugin in the `pom.xml` file. It specifies the path to the JaCoCo execution data file, which helps in generating accurate code coverage reports.
@pflynn-virtru pflynn-virtru changed the title ci: SonarCloud integration ci: SonarCloud coverage Oct 16, 2024
Added the JaCoCo Maven plugin to `nifi-tdf-nar/pom.xml` and updated the phase for the `report-aggregate` to `verify` in the main `pom.xml`. This ensures proper code coverage reports aggregation and improves build verification processes.
Configured the SonarQube properties to include the JaCoCo XML report for code coverage analysis. This ensures that SonarQube can accurately reflect the code coverage metrics generated by JaCoCo.
This commit removes the Buf setup step from the GitHub Actions workflow and replaces it with steps to configure and submit test coverage reports to SonarCloud. This change enhances the CI process by integrating code quality metrics into the build pipeline.
This change adds the ORGANIZATION environment variable to the SonarCloud report submission process. It ensures that the organization parameter is included in the POST request to the SonarCloud API, allowing correct project association under "opentdf".
Replaced manual SonarCloud report submission with official SonarCloud GitHub Action. This simplifies the workflow and leverages better integration with GitHub for PR analysis. Commented out the previous cURL-based implementation for reference.
Combines Maven test coverage and SonarCloud scan into a single command using the Sonar Maven plugin. This change simplifies the workflow by eliminating the need for a separate SonarCloud scan step.
Moved SonarQube properties from the coverage profile to the main properties section in pom.xml. This ensures better consistency and availability of these properties across all project builds.
This change sets the SONAR_TOKEN environment variable for the Maven Test Coverage step in the GitHub Actions workflow. It ensures that the SonarQube scanner can authenticate correctly using the token stored in GitHub Secrets.
The GITHUB_TOKEN was added to the environment variables for the Maven Test Coverage step to enable additional integrations. Removed the commented-out section for posting the coverage report, as it is no longer needed.
Setting the fetch-depth to 0 ensures the entire history is fetched, not just a single commit. This change is necessary for certain CI tasks that require full history such as versioning and changelog generation.
ttschampel
ttschampel previously approved these changes Oct 17, 2024
Copy link

@pflynn-virtru pflynn-virtru merged commit 9eef1e6 into main Oct 18, 2024
5 checks passed
@pflynn-virtru pflynn-virtru deleted the ci/sonar-coverage branch October 18, 2024 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants