-
-
Notifications
You must be signed in to change notification settings - Fork 179
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
Separate static analyzer task/javadoc from test execution #4852
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This improves our current workflow. Thank you!
Should be rebased onto current develop after #4853 was merged. |
I would rename the workflow from "Test & documentation" to "Analyse & Test" |
Signed-off-by: Patrick Reinhart <[email protected]>
Kudos, SonarCloud Quality Gate passed!
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some good changes, but the separate javadoc CI job doesn't make sense as it duplicates the majority of the work that has to be done. Also a couple of small issues that I have highlighted.
distribution: temurin | ||
java-version: ${{ env.DEV_JDK }} | ||
cache: 'maven' | ||
- run: mvn -V -B -q -T 2C install javadoc:javadoc -DskipTests -D'dependency-check.skip' -D'license.skip' --projects '!exist-distribution,!exist-installer' --also-make |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure if it makes sense to have the javadoc in a separate task.
As it is setup in this PR, the javadoc CI job will also call these Maven phases:
- validate
- initialize
- generate-sources
- process-sources
- generate-resources
- process-resources
- compile
- process-classes
- generate-test-sources
- process-test-sources
- generate-test-resources
- process-test-resources
- test-compile
- process-test-classes
- test
- prepare-package
- package
- pre-integration-test
- integration-test
- post-integration-test
- verify
- install
Only phases 15 and 19, i.e. test
and integration test
will be reduced (but not omitted) in this job due to the -DskipTests
short-cutting the process
methods of the maven-surefire-plugin
and maven-failsafe-plugin
. As all of these phasse are already performed in the Maven Test
CI job, separating this into a separate job has increased the amount of work required by the CI due to duplication of phases.
I think it would be better to reinstate it into the Maven Test
CI job with a condition that it is only executed on the Linux runner (as that is the fastest runner).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would this mean no unit tests anymore on windows/macos?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it would mean that only the javadoc
task would be run on Linux.
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macOS-latest] | ||
jdk: ['17'] | ||
jdk: [ '17' ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be - ${{ env.DEV_JDK }}
?
@@ -21,9 +59,9 @@ jobs: | |||
cache: 'maven' | |||
- name: Maven Test | |||
timeout-minutes: 60 | |||
run: mvn -V -B -DtrimStackTrace=false -D"maven.resolver.transport"="wagon" clean verify | |||
run: mvn -V -B verify -D'dependency-check.skip' -D'license.skip' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we reinstate -DtrimStackTrace=false
please?
Combines Test & JavaDoc Workflow to one separating single tasks as follows: