Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

Suppress spotbugs PA_PUBLIC_PRIMITIVE_ATTRIBUTE warnings #290

Closed

Conversation

MarkEWaite
Copy link
Contributor

Suppress spotbugs PA_PUBLIC_PRIMITIVE_ATTRIBUTE warnings

The improve a plugin tutorial describes the technique used here with an exclusions file. The specific exclusion for PA_PUBLIC_PRIMITIVE_ATTRIBUTE has been confirmed by Jenkins developers that it is not helpful in a Jenkins plugin.

Jenkins core PR-8803 describes the changes that were made in Jenkins core and in many Jenkins plugins to suppress the PA_PUBLIC_PRIMITIVE_ATTRIBUTE spotbugs warning.

Testing done

Confirmed that spotbugs warnings are visible before this change and are resolved after this change. No change to Java source code or the pom file. Uses the default location of the spotbugs suppression file from the parent pom.

Submitter checklist

  • Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
  • Ensure that the pull request title represents the desired changelog entry
  • Please describe what you did
  • Link to relevant issues in GitHub or Jira
  • Link to relevant pull requests, esp. upstream and downstream changes
  • Ensure you have provided tests - that demonstrates feature works or fixes the issue

https://www.jenkins.io/doc/developer/tutorial-improve/add-more-spotbugs-checks/
describes the technique used here with an exclusions file.  The specific
exclusion for PA_PUBLIC_PRIMITIVE_ATTRIBUTE has been confirmed by Jenkins
developers that it is not helpful in a Jenkins plugin.

jenkinsci/jenkins#8803 describes the changes
that were made in Jenkins core and in many Jenkins plugins to suppress
the PA_PUBLIC_PRIMITIVE_ATTRIBUTE spotbugs warning.
@MarkEWaite MarkEWaite requested a review from a team as a code owner October 9, 2024 11:57
@MarkEWaite
Copy link
Contributor Author

MarkEWaite commented Oct 9, 2024

@MarkEWaite
Copy link
Contributor Author

Closing in favor of:

@MarkEWaite MarkEWaite closed this Oct 9, 2024
@MarkEWaite MarkEWaite deleted the suppress-spotbugs-warnings branch October 9, 2024 14:08
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant