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

[INFRA-2294][INFRA-2000] Enable Warnings Next Generation Plugin #121

Merged
merged 17 commits into from
Jul 27, 2020

Conversation

uhafner
Copy link
Contributor

@uhafner uhafner commented Nov 26, 2019

This PR will remove the old static analysis configuration and replace it with a configuration of the
Warnings Next Generation plugin. See example output to get an impression of the new configuration.

I removed the old configuration of Checkstyle and Findbugs and replaced it with the corresponding Warnings plugin configuration. There are two open things that need to be discussed (and may be added in another PR):

  • I removed the maven configuration on how to start the tools. I'm not sure if I am using Maven the wrong way but I think that this part should belong to the pom and not into the buildPlugin step. In my jobs I configure all analysis tools in the pom so that maven verify will invoke automatically the static analysis tools that I want (with my configuration files and options). The warnings plugin is smart enough to not break the build if there are no reports written.
  • I did not yet activate the quality gates. I'm not sure if someone already is using that feature? A total number of 0 warnings quite hard to achieve.

Detailed changes summary:

  • Removed FindBugs and CheckStyle maven configuration.
  • Removed old FindBugs and CheckStyle parameters for old plugins.
  • Enabled warnings-ng reporters for Maven, Java and JavaDoc.
  • Enabled warnings-ng reporters for CheckStyle, PMD, CPD, and SpotBugs.
  • Enabled warnings-ng reporters for Open Tasks.
  • Add jar files to the archive as well (otherwise the example job will fail).

Removed FindBugs and CheckStyle maven configuration.
Removed old FindBugs and CheckStyle parameters for old plugins.
Enabled warnings-ng reporters for Maven, Java and JavaDoc.
Enabled warnings-ng reporters for CheckStyle, PMD, and FindBugs.
Enabled warnings-ng reporters for Open Tasks.
@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-11-26T08:56:04.454Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.61 s - in InfraStepTests
[2019-11-26T08:56:05.019Z] [INFO] 
[2019-11-26T08:56:05.019Z] [INFO] Results:
[2019-11-26T08:56:05.019Z] [INFO] 
[2019-11-26T08:56:05.019Z] [ERROR] Errors: 
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-11-26T08:56:05.019Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-11-26T08:56:05.020Z] [INFO] 
[2019-11-26T08:56:05.020Z] [ERROR] Tests run: 41, Failures: 0, Errors: 7, Skipped: 1
[2019-11-26T08:56:05.020Z] [INFO] 
[2019-11-26T08:56:05.020Z] [INFO] ------------------------------------------------------------------------
[2019-11-26T08:56:05.020Z] [INFO] BUILD FAILURE
[2019-11-26T08:56:05.020Z] [INFO] ------------------------------------------------------------------------
[2019-11-26T08:56:05.020Z] [INFO] Total time:  14.303 s
[2019-11-26T08:56:05.020Z] [INFO] Finished at: 2019-11-26T08:56:04Z
[2019-11-26T08:56:05.020Z] [INFO] ------------------------------------------------------------------------
[2019-11-26T08:56:05.020Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-11-26T08:56:05.020Z] [ERROR] 
[2019-11-26T08:56:05.020Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-11-26T08:56:05.020Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-11-26T08:56:05.020Z] [ERROR] -> [Help 1]
[2019-11-26T08:56:05.020Z] [ERROR] 
[2019-11-26T08:56:05.020Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-11-26T08:56:05.020Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-11-26T08:56:05.020Z] [ERROR] 
[2019-11-26T08:56:05.020Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-11-26T08:56:05.020Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-11-26T08:56:05.282Z] Post stage
[2019-11-26T08:56:05.309Z] [Pipeline] junit
[2019-11-26T08:56:05.333Z] Recording test results
[2019-11-26T08:56:06.653Z] [Pipeline] }
[2019-11-26T08:56:06.795Z] [Pipeline] // stage
[2019-11-26T08:56:06.916Z] [Pipeline] }
[2019-11-26T08:56:07.078Z] [Pipeline] // timestamps
[2019-11-26T08:56:07.224Z] [Pipeline] }
[2019-11-26T08:56:07.454Z] [Pipeline] // withEnv
[2019-11-26T08:56:07.623Z] [Pipeline] }
[2019-11-26T08:56:07.722Z] [Pipeline] // node
[2019-11-26T08:56:08.041Z] [Pipeline] End of Pipeline
[2019-11-26T08:56:09.702Z] 
[2019-11-26T08:56:09.702Z] GitHub has been notified of this commit’s build result
[2019-11-26T08:56:09.702Z] 
[2019-11-26T08:56:09.702Z] ERROR: script returned exit code 1
[2019-11-26T08:56:09.702Z] Finished: FAILURE

Powered by the Comment Logger

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-11-27T07:56:37.049Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.664 s - in InfraStepTests
[2019-11-27T07:56:37.307Z] [INFO] 
[2019-11-27T07:56:37.307Z] [INFO] Results:
[2019-11-27T07:56:37.307Z] [INFO] 
[2019-11-27T07:56:37.307Z] [ERROR] Errors: 
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-11-27T07:56:37.307Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-11-27T07:56:37.307Z] [INFO] 
[2019-11-27T07:56:37.307Z] [ERROR] Tests run: 41, Failures: 0, Errors: 7, Skipped: 1
[2019-11-27T07:56:37.307Z] [INFO] 
[2019-11-27T07:56:37.307Z] [INFO] ------------------------------------------------------------------------
[2019-11-27T07:56:37.307Z] [INFO] BUILD FAILURE
[2019-11-27T07:56:37.307Z] [INFO] ------------------------------------------------------------------------
[2019-11-27T07:56:37.307Z] [INFO] Total time:  16.686 s
[2019-11-27T07:56:37.307Z] [INFO] Finished at: 2019-11-27T07:56:37Z
[2019-11-27T07:56:37.307Z] [INFO] ------------------------------------------------------------------------
[2019-11-27T07:56:37.307Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-11-27T07:56:37.307Z] [ERROR] 
[2019-11-27T07:56:37.307Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-11-27T07:56:37.307Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-11-27T07:56:37.307Z] [ERROR] -> [Help 1]
[2019-11-27T07:56:37.307Z] [ERROR] 
[2019-11-27T07:56:37.307Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-11-27T07:56:37.307Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-11-27T07:56:37.307Z] [ERROR] 
[2019-11-27T07:56:37.307Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-11-27T07:56:37.307Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-11-27T07:56:37.683Z] Post stage
[2019-11-27T07:56:37.906Z] [Pipeline] junit
[2019-11-27T07:56:37.956Z] Recording test results
[2019-11-27T07:56:38.971Z] [Pipeline] }
[2019-11-27T07:56:39.053Z] [Pipeline] // stage
[2019-11-27T07:56:39.118Z] [Pipeline] }
[2019-11-27T07:56:39.156Z] [Pipeline] // timestamps
[2019-11-27T07:56:39.192Z] [Pipeline] }
[2019-11-27T07:56:39.230Z] [Pipeline] // withEnv
[2019-11-27T07:56:39.313Z] [Pipeline] }
[2019-11-27T07:56:39.354Z] [Pipeline] // node
[2019-11-27T07:56:39.404Z] [Pipeline] End of Pipeline
[2019-11-27T07:56:40.891Z] 
[2019-11-27T07:56:40.891Z] GitHub has been notified of this commit’s build result
[2019-11-27T07:56:40.891Z] 
[2019-11-27T07:56:40.892Z] ERROR: script returned exit code 1
[2019-11-27T07:56:40.892Z] Finished: FAILURE

Powered by the Comment Logger

@jtnord
Copy link
Contributor

jtnord commented Dec 18, 2019

I removed the maven configuration on how to start the tools

spotbugs is run as part of verify at least in semi recent versions of the plugin-pom

However it will fail the build and we expect an unstable build for testish (of which spotbugs is one) failures, so I think you still need to tell the build not to fail for spotbugs issues.

checkstyle is not as actually getting a consensus on any style is problematic :)

I did not yet activate the quality gates.
I did not yet activate the quality gates. I'm not sure if someone already is using that feature

There are at least some plugins that do. Actually this is an issue I had recently with wanrings ng - the quality gate is acrross all tools not just specific ones that it used to be (which allows marking unstable for any spotbugs issue, but just reporting TODOs checkstyle etc).

https://github.com/search?p=2&q=org%3Ajenkinsci+findbugs+filename%3AJenkinsfile&type=Code shows quite a few (on page 2 onwards)

@zbynek
Copy link

zbynek commented Dec 18, 2019

@jtnord you can set a quality gates for a subset of tools using two recordIssues steps: https://github.com/geogebra/geogebra/blob/5.0.570.0/Jenkinsfile#L44

@uhafner
Copy link
Contributor Author

uhafner commented Dec 18, 2019

Yes, indeed, you can specify a quality gate for each step, this was one of the main requirements for the warnings-ng redesign.

@uhafner
Copy link
Contributor Author

uhafner commented Dec 18, 2019

Does that mean it is ok to remove the spotbugs:spotbugs part but we need to leave the failOnError=false flags?

@uhafner
Copy link
Contributor Author

uhafner commented Dec 18, 2019

What still sounds for me as pipeline newbie kind of strange is that we need to remodel the parameters of my steps as parameters for the buildPlugin method. As a plugin author I would feel more comfortable with some kind of closure that I am adding to the step (but that might not be possible with pipelines).

So in pseudo-code it would be nice to have:

buildPlugin(
    post: () -> {
          recordIssues tools: [java(), javaDoc()], aggregatingResults: 'true', id: 'java', name: 'Java'
          publishCoverage adapters: [jacocoAdapter('target/site/jacoco/jacoco.xml')]
          ...
    }
)

@jtnord
Copy link
Contributor

jtnord commented Dec 18, 2019

@jtnord you can set a quality gates for a subset of tools using two recordIssues steps: https://github.com/geogebra/geogebra/blob/5.0.570.0/Jenkinsfile#L44

but if you want an aggregated report... maybe we where doing something else wrong. I will try and reproduce and ask on the users list

What still sounds for me as pipeline newbie kind of strange is that we need to remodel the parameters of my steps as parameters for the buildPlugin method

you can do that but it's the old way (not sure of all the reasons) but it can mean a plugin upgrade change could require reconfig of many jobs rather than a central place.
also does not help with making findings not fail the build and getting Jenkins to do it via warnings-ng. (a rather contrived example would be if the unsupported findings plugin had a security vuln that would not be fixed as it's replaced by warnings-ng that meant we would uninstall that plugin)

@jtnord
Copy link
Contributor

jtnord commented Dec 18, 2019

Does that mean it is ok to remove the spotbugs:spotbugs part but we need to leave the failOnError=false flags?

yes. the failOnError should be the spotbugs flag not findings as that is about to be removed (or use both)

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-12-19T15:23:45.240Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.633 s - in InfraStepTests
[2019-12-19T15:23:45.806Z] [INFO] 
[2019-12-19T15:23:45.806Z] [INFO] Results:
[2019-12-19T15:23:45.806Z] [INFO] 
[2019-12-19T15:23:45.806Z] [ERROR] Errors: 
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-12-19T15:23:45.806Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-12-19T15:23:45.806Z] [INFO] 
[2019-12-19T15:23:45.806Z] [ERROR] Tests run: 41, Failures: 0, Errors: 7, Skipped: 1
[2019-12-19T15:23:45.806Z] [INFO] 
[2019-12-19T15:23:45.806Z] [INFO] ------------------------------------------------------------------------
[2019-12-19T15:23:45.806Z] [INFO] BUILD FAILURE
[2019-12-19T15:23:45.806Z] [INFO] ------------------------------------------------------------------------
[2019-12-19T15:23:45.806Z] [INFO] Total time:  15.295 s
[2019-12-19T15:23:45.806Z] [INFO] Finished at: 2019-12-19T15:23:45Z
[2019-12-19T15:23:45.806Z] [INFO] ------------------------------------------------------------------------
[2019-12-19T15:23:45.806Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-12-19T15:23:45.806Z] [ERROR] 
[2019-12-19T15:23:45.806Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-12-19T15:23:45.806Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-12-19T15:23:45.806Z] [ERROR] -> [Help 1]
[2019-12-19T15:23:45.806Z] [ERROR] 
[2019-12-19T15:23:45.806Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-12-19T15:23:45.806Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-12-19T15:23:45.806Z] [ERROR] 
[2019-12-19T15:23:45.806Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-12-19T15:23:45.806Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-12-19T15:23:45.854Z] Post stage
[2019-12-19T15:23:45.876Z] [Pipeline] junit
[2019-12-19T15:23:45.889Z] Recording test results
[2019-12-19T15:23:46.750Z] [Pipeline] }
[2019-12-19T15:23:46.807Z] [Pipeline] // stage
[2019-12-19T15:23:46.870Z] [Pipeline] }
[2019-12-19T15:23:46.906Z] [Pipeline] // timestamps
[2019-12-19T15:23:46.934Z] [Pipeline] }
[2019-12-19T15:23:46.969Z] [Pipeline] // withEnv
[2019-12-19T15:23:46.996Z] [Pipeline] }
[2019-12-19T15:23:47.033Z] [Pipeline] // node
[2019-12-19T15:23:47.090Z] [Pipeline] End of Pipeline
[2019-12-19T15:23:48.709Z] 
[2019-12-19T15:23:48.709Z] GitHub has been notified of this commit’s build result
[2019-12-19T15:23:48.709Z] 
[2019-12-19T15:23:48.709Z] ERROR: script returned exit code 1
[2019-12-19T15:23:48.709Z] Finished: FAILURE

Powered by the Comment Logger

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-12-23T15:56:45.524Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.434 s - in InfraStepTests
[2019-12-23T15:56:46.090Z] [INFO] 
[2019-12-23T15:56:46.090Z] [INFO] Results:
[2019-12-23T15:56:46.090Z] [INFO] 
[2019-12-23T15:56:46.090Z] [ERROR] Errors: 
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-12-23T15:56:46.090Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-12-23T15:56:46.090Z] [INFO] 
[2019-12-23T15:56:46.090Z] [ERROR] Tests run: 41, Failures: 0, Errors: 7, Skipped: 1
[2019-12-23T15:56:46.090Z] [INFO] 
[2019-12-23T15:56:46.090Z] [INFO] ------------------------------------------------------------------------
[2019-12-23T15:56:46.090Z] [INFO] BUILD FAILURE
[2019-12-23T15:56:46.090Z] [INFO] ------------------------------------------------------------------------
[2019-12-23T15:56:46.090Z] [INFO] Total time:  14.212 s
[2019-12-23T15:56:46.090Z] [INFO] Finished at: 2019-12-23T15:56:45Z
[2019-12-23T15:56:46.090Z] [INFO] ------------------------------------------------------------------------
[2019-12-23T15:56:46.090Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-12-23T15:56:46.090Z] [ERROR] 
[2019-12-23T15:56:46.090Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-12-23T15:56:46.090Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-12-23T15:56:46.090Z] [ERROR] -> [Help 1]
[2019-12-23T15:56:46.090Z] [ERROR] 
[2019-12-23T15:56:46.090Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-12-23T15:56:46.090Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-12-23T15:56:46.090Z] [ERROR] 
[2019-12-23T15:56:46.090Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-12-23T15:56:46.090Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-12-23T15:56:46.172Z] Post stage
[2019-12-23T15:56:46.194Z] [Pipeline] junit
[2019-12-23T15:56:46.233Z] Recording test results
[2019-12-23T15:56:47.127Z] [Pipeline] }
[2019-12-23T15:56:47.167Z] [Pipeline] // stage
[2019-12-23T15:56:47.206Z] [Pipeline] }
[2019-12-23T15:56:47.242Z] [Pipeline] // timestamps
[2019-12-23T15:56:47.275Z] [Pipeline] }
[2019-12-23T15:56:47.312Z] [Pipeline] // withEnv
[2019-12-23T15:56:47.360Z] [Pipeline] }
[2019-12-23T15:56:47.406Z] [Pipeline] // node
[2019-12-23T15:56:47.456Z] [Pipeline] End of Pipeline
[2019-12-23T15:56:49.013Z] 
[2019-12-23T15:56:49.013Z] GitHub has been notified of this commit’s build result
[2019-12-23T15:56:49.013Z] 
[2019-12-23T15:56:49.013Z] ERROR: script returned exit code 1
[2019-12-23T15:56:49.013Z] Finished: FAILURE

Powered by the Comment Logger

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-12-24T15:56:50.683Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.647 s - in InfraStepTests
[2019-12-24T15:56:50.942Z] [INFO] 
[2019-12-24T15:56:50.942Z] [INFO] Results:
[2019-12-24T15:56:50.942Z] [INFO] 
[2019-12-24T15:56:50.942Z] [ERROR] Errors: 
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-12-24T15:56:50.942Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-12-24T15:56:50.942Z] [INFO] 
[2019-12-24T15:56:50.942Z] [ERROR] Tests run: 41, Failures: 0, Errors: 7, Skipped: 1
[2019-12-24T15:56:50.942Z] [INFO] 
[2019-12-24T15:56:50.942Z] [INFO] ------------------------------------------------------------------------
[2019-12-24T15:56:50.942Z] [INFO] BUILD FAILURE
[2019-12-24T15:56:50.942Z] [INFO] ------------------------------------------------------------------------
[2019-12-24T15:56:50.942Z] [INFO] Total time:  19.366 s
[2019-12-24T15:56:50.942Z] [INFO] Finished at: 2019-12-24T15:56:50Z
[2019-12-24T15:56:50.942Z] [INFO] ------------------------------------------------------------------------
[2019-12-24T15:56:50.942Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-12-24T15:56:50.942Z] [ERROR] 
[2019-12-24T15:56:50.942Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-12-24T15:56:50.942Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-12-24T15:56:50.942Z] [ERROR] -> [Help 1]
[2019-12-24T15:56:50.942Z] [ERROR] 
[2019-12-24T15:56:50.942Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-12-24T15:56:50.942Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-12-24T15:56:50.942Z] [ERROR] 
[2019-12-24T15:56:50.942Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-12-24T15:56:50.942Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-12-24T15:56:51.011Z] Post stage
[2019-12-24T15:56:51.032Z] [Pipeline] junit
[2019-12-24T15:56:51.044Z] Recording test results
[2019-12-24T15:56:52.036Z] [Pipeline] }
[2019-12-24T15:56:52.072Z] [Pipeline] // stage
[2019-12-24T15:56:52.097Z] [Pipeline] }
[2019-12-24T15:56:52.131Z] [Pipeline] // timestamps
[2019-12-24T15:56:52.155Z] [Pipeline] }
[2019-12-24T15:56:52.185Z] [Pipeline] // withEnv
[2019-12-24T15:56:52.208Z] [Pipeline] }
[2019-12-24T15:56:52.264Z] [Pipeline] // node
[2019-12-24T15:56:52.305Z] [Pipeline] End of Pipeline
[2019-12-24T15:56:53.916Z] 
[2019-12-24T15:56:53.916Z] GitHub has been notified of this commit’s build result
[2019-12-24T15:56:53.916Z] 
[2019-12-24T15:56:53.916Z] ERROR: script returned exit code 1
[2019-12-24T15:56:53.916Z] Finished: FAILURE

Powered by the Comment Logger

@darxriggs
Copy link
Contributor

The buildPluginWithGradle step should also be adapted.

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-12-27T15:57:35.221Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.561 s - in InfraStepTests
[2019-12-27T15:57:35.794Z] [INFO] 
[2019-12-27T15:57:35.794Z] [INFO] Results:
[2019-12-27T15:57:35.794Z] [INFO] 
[2019-12-27T15:57:35.794Z] [ERROR] Errors: 
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-12-27T15:57:35.794Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-12-27T15:57:35.794Z] [INFO] 
[2019-12-27T15:57:35.794Z] [ERROR] Tests run: 41, Failures: 0, Errors: 7, Skipped: 1
[2019-12-27T15:57:35.794Z] [INFO] 
[2019-12-27T15:57:35.794Z] [INFO] ------------------------------------------------------------------------
[2019-12-27T15:57:35.794Z] [INFO] BUILD FAILURE
[2019-12-27T15:57:35.794Z] [INFO] ------------------------------------------------------------------------
[2019-12-27T15:57:35.794Z] [INFO] Total time:  15.970 s
[2019-12-27T15:57:35.794Z] [INFO] Finished at: 2019-12-27T15:57:35Z
[2019-12-27T15:57:35.794Z] [INFO] ------------------------------------------------------------------------
[2019-12-27T15:57:35.794Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-12-27T15:57:35.794Z] [ERROR] 
[2019-12-27T15:57:35.794Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-12-27T15:57:35.794Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-12-27T15:57:35.794Z] [ERROR] -> [Help 1]
[2019-12-27T15:57:35.794Z] [ERROR] 
[2019-12-27T15:57:35.794Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-12-27T15:57:35.794Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-12-27T15:57:35.794Z] [ERROR] 
[2019-12-27T15:57:35.794Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-12-27T15:57:35.794Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-12-27T15:57:35.851Z] Post stage
[2019-12-27T15:57:35.895Z] [Pipeline] junit
[2019-12-27T15:57:35.910Z] Recording test results
[2019-12-27T15:57:36.884Z] [Pipeline] }
[2019-12-27T15:57:36.915Z] [Pipeline] // stage
[2019-12-27T15:57:36.967Z] [Pipeline] }
[2019-12-27T15:57:36.998Z] [Pipeline] // timestamps
[2019-12-27T15:57:37.055Z] [Pipeline] }
[2019-12-27T15:57:37.085Z] [Pipeline] // withEnv
[2019-12-27T15:57:37.111Z] [Pipeline] }
[2019-12-27T15:57:37.208Z] [Pipeline] // node
[2019-12-27T15:57:37.252Z] [Pipeline] End of Pipeline
[2019-12-27T15:57:38.802Z] 
[2019-12-27T15:57:38.802Z] GitHub has been notified of this commit’s build result
[2019-12-27T15:57:38.802Z] 
[2019-12-27T15:57:38.802Z] ERROR: script returned exit code 1
[2019-12-27T15:57:38.802Z] Finished: FAILURE

Powered by the Comment Logger

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-12-30T15:56:50.036Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.727 s - in InfraStepTests
[2019-12-30T15:56:50.294Z] [INFO] 
[2019-12-30T15:56:50.294Z] [INFO] Results:
[2019-12-30T15:56:50.294Z] [INFO] 
[2019-12-30T15:56:50.294Z] [ERROR] Errors: 
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-12-30T15:56:50.294Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-12-30T15:56:50.294Z] [INFO] 
[2019-12-30T15:56:50.294Z] [ERROR] Tests run: 45, Failures: 0, Errors: 7, Skipped: 1
[2019-12-30T15:56:50.294Z] [INFO] 
[2019-12-30T15:56:50.294Z] [INFO] ------------------------------------------------------------------------
[2019-12-30T15:56:50.294Z] [INFO] BUILD FAILURE
[2019-12-30T15:56:50.294Z] [INFO] ------------------------------------------------------------------------
[2019-12-30T15:56:50.294Z] [INFO] Total time:  17.078 s
[2019-12-30T15:56:50.294Z] [INFO] Finished at: 2019-12-30T15:56:50Z
[2019-12-30T15:56:50.294Z] [INFO] ------------------------------------------------------------------------
[2019-12-30T15:56:50.294Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-12-30T15:56:50.294Z] [ERROR] 
[2019-12-30T15:56:50.294Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-12-30T15:56:50.294Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-12-30T15:56:50.294Z] [ERROR] -> [Help 1]
[2019-12-30T15:56:50.294Z] [ERROR] 
[2019-12-30T15:56:50.294Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-12-30T15:56:50.294Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-12-30T15:56:50.294Z] [ERROR] 
[2019-12-30T15:56:50.294Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-12-30T15:56:50.294Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-12-30T15:56:50.348Z] Post stage
[2019-12-30T15:56:50.371Z] [Pipeline] junit
[2019-12-30T15:56:50.384Z] Recording test results
[2019-12-30T15:56:51.391Z] [Pipeline] }
[2019-12-30T15:56:51.469Z] [Pipeline] // stage
[2019-12-30T15:56:51.501Z] [Pipeline] }
[2019-12-30T15:56:51.536Z] [Pipeline] // timestamps
[2019-12-30T15:56:51.567Z] [Pipeline] }
[2019-12-30T15:56:51.600Z] [Pipeline] // withEnv
[2019-12-30T15:56:51.628Z] [Pipeline] }
[2019-12-30T15:56:51.659Z] [Pipeline] // node
[2019-12-30T15:56:51.741Z] [Pipeline] End of Pipeline
[2019-12-30T15:56:53.402Z] 
[2019-12-30T15:56:53.402Z] GitHub has been notified of this commit’s build result
[2019-12-30T15:56:53.402Z] 
[2019-12-30T15:56:53.402Z] ERROR: script returned exit code 1
[2019-12-30T15:56:53.402Z] Finished: FAILURE

Powered by the Comment Logger

@jenkinsadmin
Copy link

Build failed; the context from the latest run is:

Expand to view
[2019-12-31T15:57:42.180Z] [WARNING] Tests run: 8, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.548 s - in InfraStepTests
[2019-12-31T15:57:42.745Z] [INFO] 
[2019-12-31T15:57:42.745Z] [INFO] Results:
[2019-12-31T15:57:42.745Z] [INFO] 
[2019-12-31T15:57:42.745Z] [ERROR] Errors: 
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_checkstyle_archive:280 » Runtime li...
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_configurations_and_incrementals:297 » Runtime
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults:177 » Runtime linux-8 - No...
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_defaults_with_gradle:234 » Runtime ...
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_findbugs_archive:267 » Runtime linu...
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_with_timeout:207 » Runtime linux-8 - No ...
[2019-12-31T15:57:42.745Z] [ERROR]   BuildPluginStepTests.test_buildPlugin_without_tests:220 » Runtime linux-8 - No...
[2019-12-31T15:57:42.745Z] [INFO] 
[2019-12-31T15:57:42.745Z] [ERROR] Tests run: 45, Failures: 0, Errors: 7, Skipped: 1
[2019-12-31T15:57:42.745Z] [INFO] 
[2019-12-31T15:57:42.745Z] [INFO] ------------------------------------------------------------------------
[2019-12-31T15:57:42.745Z] [INFO] BUILD FAILURE
[2019-12-31T15:57:42.745Z] [INFO] ------------------------------------------------------------------------
[2019-12-31T15:57:42.745Z] [INFO] Total time:  16.017 s
[2019-12-31T15:57:42.745Z] [INFO] Finished at: 2019-12-31T15:57:42Z
[2019-12-31T15:57:42.745Z] [INFO] ------------------------------------------------------------------------
[2019-12-31T15:57:42.745Z] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pipeline-library: There are test failures.
[2019-12-31T15:57:42.745Z] [ERROR] 
[2019-12-31T15:57:42.745Z] [ERROR] Please refer to /home/jenkins/workspace/Infra_pipeline-library_PR-121/target/surefire-reports for the individual test results.
[2019-12-31T15:57:42.745Z] [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[2019-12-31T15:57:42.745Z] [ERROR] -> [Help 1]
[2019-12-31T15:57:42.745Z] [ERROR] 
[2019-12-31T15:57:42.745Z] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[2019-12-31T15:57:42.745Z] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[2019-12-31T15:57:42.745Z] [ERROR] 
[2019-12-31T15:57:42.745Z] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[2019-12-31T15:57:42.745Z] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[2019-12-31T15:57:42.817Z] Post stage
[2019-12-31T15:57:42.841Z] [Pipeline] junit
[2019-12-31T15:57:42.860Z] Recording test results
[2019-12-31T15:57:43.798Z] [Pipeline] }
[2019-12-31T15:57:43.877Z] [Pipeline] // stage
[2019-12-31T15:57:43.932Z] [Pipeline] }
[2019-12-31T15:57:43.982Z] [Pipeline] // timestamps
[2019-12-31T15:57:44.027Z] [Pipeline] }
[2019-12-31T15:57:44.078Z] [Pipeline] // withEnv
[2019-12-31T15:57:44.124Z] [Pipeline] }
[2019-12-31T15:57:44.178Z] [Pipeline] // node
[2019-12-31T15:57:44.317Z] [Pipeline] End of Pipeline
[2019-12-31T15:57:46.000Z] 
[2019-12-31T15:57:46.000Z] GitHub has been notified of this commit’s build result
[2019-12-31T15:57:46.000Z] 
[2019-12-31T15:57:46.000Z] ERROR: script returned exit code 1
[2019-12-31T15:57:46.000Z] Finished: FAILURE

Powered by the Comment Logger

# Conflicts:
#	vars/buildPlugin.groovy
@uhafner
Copy link
Contributor Author

uhafner commented Jan 24, 2020

Does someone know how to fix the unit test failure

No signature of method: buildPlugin.mavenConsole() is applicable for argument types: () values: []

Do I need to register my steps somewhere?

@uhafner
Copy link
Contributor Author

uhafner commented Jan 24, 2020

The step works perfectly in our CI build

@v1v
Copy link
Contributor

v1v commented Feb 20, 2020

@uhafner regarding buildPlugin.mavenConsole() , you need to mock it with something like the below snippet:

class BuildPluginStepTests extends BasePipelineTest {
...
  void setUp() throws Exception {
...
    helper.registerAllowedMethod('checkStyle', [], { true })
    helper.registerAllowedMethod('java', [], { true })
    helper.registerAllowedMethod('javaDoc', [], { true })
    helper.registerAllowedMethod('mavenConsole', [], { true })
    helper.registerAllowedMethod('pmdParser', [], { true })
    helper.registerAllowedMethod('spotBugs', [], { true })
    helper.registerAllowedMethod('recordIssues', [Map.class], { true })
    helper.registerAllowedMethod('taskScanner', [Map.class], { true })
...

Cheers

@uhafner uhafner marked this pull request as ready for review February 23, 2020 22:02
@uhafner uhafner requested a review from a team as a code owner February 23, 2020 22:02
v1v
v1v previously approved these changes Feb 26, 2020
@timja
Copy link
Member

timja commented Jul 1, 2020

JOB_NAME is available for the referenceJobName field

timja added a commit to timja/dimensionsscm-plugin that referenced this pull request Jul 25, 2020
Spotbugs reporting is being enabled by default in jenkins-infra/pipeline-library#121, update to parent pom 4.x to use spotbugs instead of findbugs.
@timja timja requested a review from oleg-nenashev July 25, 2020 15:19
@timja
Copy link
Member

timja commented Jul 25, 2020

@oleg-nenashev @slide @uhafner I've opened PRs to every single plugin that uses the findbugs or checkstyle configurations.

are we good to go ahead?

@slide
Copy link
Contributor

slide commented Jul 25, 2020

@timja goes above and beyond again! I'm happy to move forward

@timja timja requested a review from slide July 25, 2020 15:25
tomasbjerre pushed a commit to jenkinsci/violation-comments-to-stash-plugin that referenced this pull request Jul 26, 2020
Spotbugs reporting is being enabled by default in jenkins-infra/pipeline-library#121, update to parent pom 4.x to use spotbugs instead of findbugs.
Copy link
Contributor

@oleg-nenashev oleg-nenashev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am fine with going ahead and merging it. I will release it with a breaking change notice

@timja timja added the breaking label Jul 27, 2020
@timja timja merged commit 98fd6ef into jenkins-infra:master Jul 27, 2020
chriskilding pushed a commit to jenkinsci/aws-secrets-manager-credentials-provider-plugin that referenced this pull request Jul 27, 2020
Checkstyle and Spotbugs were added to the standard build configuration in jenkins-infra/pipeline-library#121.
trendChartType: 'TOOLS_ONLY',
referenceJobName: referenceJobName
recordIssues enabledForFailure: true,
tools: [java(), javaDoc()],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With the addition of Checks, we are suddenly getting tons and tons of warnings. For example, https://github.com/jenkinsci/ldap-plugin/pull/48/files is practically illegible because of irrelevant, low-priority warnings like

NORMAL:
no @param for rootDN

Worse, checks-api apparently submits annotations even for lines of code which are not modified by a PR and GH displays every annotation, so the Files tab is lost in annotations which are not even related to the diff.

Can we at least turn off display of low-priority Javadoc warnings?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, do not seem to be getting these Checks results in PRs on other plugins. Not sure what would be different here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could work around this by doing one of:

  • fixing the javadoc issues
  • adjusting the maven javadoc plugin not to complain about these
  • extending the javadoc / java parts of buildPlugin to allow overriding the configuration like you can do for spotbugs, checkstyle, pmd already and then do something like buildPlugin(javadoc: skipPublishingChecks: true) in your plugin
  • turning checks off by default for javadoc

thoughts?

cc @XiongKezhi

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

adjusting the maven javadoc plugin not to complain about these

Could be done in plugin-pom I guess. I care about genuine problems—@link target missing, mistyped tag, etc.—but not just silliness like missing @param which is true for most methods in the Jenkins source base.

Copy link

@XiongKezhi XiongKezhi Aug 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those warnings are also reported by the warnings-ng plugin: https://ci.jenkins.io/job/Plugins/job/ldap-plugin/job/PR-48/3/, they are just scanned from Java or JavaDoc log files, we can't really do much about the scan and collect process. But you can control the minimal severity of issues to report:

recordIssues tool: java(pattern: '*.log'), minimumSeverity: 'HIGH'

But this is the pipeline grammar of warnings-ng, I'm not sure how to override the configurations in buildPlugin, maybe buildPlugin(java: minimumSeverity: 'LOW')? @timja

Also, do you think we should provide another configuration for minimal severity beside the warnings-ng one to only control the published checks?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don’t think so, just need to configure warnings ng / the Pom appropriately

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see #154

chriskilding pushed a commit to jenkinsci/aws-secrets-manager-credentials-provider-plugin that referenced this pull request Sep 16, 2020
Checkstyle and Spotbugs were added to the standard build configuration in jenkins-infra/pipeline-library#121.
jetersen pushed a commit to jenkinsci/accurev-plugin that referenced this pull request Oct 7, 2020
Spotbugs reporting is being enabled by default in jenkins-infra/pipeline-library#121, update to parent pom 4.x to use spotbugs instead of findbugs.
aakoch pushed a commit to aakoch/violation-comments-to-stash-plugin that referenced this pull request Dec 12, 2020
Spotbugs reporting is being enabled by default in jenkins-infra/pipeline-library#121, update to parent pom 4.x to use spotbugs instead of findbugs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet