Skip to content

Commit

Permalink
Omit spotbugs CT_CONSTRUCTOR_THROWS visitor (#108)
Browse files Browse the repository at this point in the history
From jenkinsci/plugin-pom#869 (comment)

> Discussion in spotbugs/spotbugs#2695
> https://wiki.sei.cmu.edu/confluence/display/java/OBJ11-J.+Be+wary+of+letting+constructors+throw+exceptions
> seems to relate to libraries used with SecurityManager which is dead
> and certainly does not apply to Jenkins; we do not expect untrusted code
> to be running inside the controller JVM, and it does not seem plausible
> that finalizer abuse would happen by accident.
  • Loading branch information
MarkEWaite authored Dec 21, 2023
1 parent eb5b402 commit 1addec7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
3 changes: 3 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@
<!-- TODO: Remove when plugin pom is using this version or newer -->
<!-- https://github.com/jenkinsci/plugin-pom/pull/869 -->
<spotbugs-maven-plugin.version>4.8.2.0</spotbugs-maven-plugin.version>
<!-- TODO: Remove when plugin pom includes this omitVisitors -->
<!-- https://github.com/jenkinsci/plugin-pom/pull/869 -->
<spotbugs.omitVisitors>ConstructorThrow,FindReturnRef</spotbugs.omitVisitors>
<spotbugs.threshold>Low</spotbugs.threshold>
<surefire.useFile>false</surefire.useFile>
<useBeta>true</useBeta>
Expand Down
7 changes: 0 additions & 7 deletions src/spotbugs/excludesFilter.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,6 @@
Exclusions in this section have been triaged and determined to be
false positives or not relevant for this plugin.
-->
<Match>
<Bug pattern="CT_CONSTRUCTOR_THROW" />
<Or>
<Class name="org.jenkinsci.plugins.cloudstats.CloudStatistics" />
<Class name="org.jenkinsci.plugins.cloudstats.CyclicThreadSafeCollection" />
</Or>
</Match>
<Match>
<Bug pattern="SE_NO_SERIALVERSIONID" />
<Or>
Expand Down

0 comments on commit 1addec7

Please sign in to comment.