joseluisll opened a new pull request, #8755:
URL: https://github.com/apache/hadoop/pull/8755
### Description of PR
`hadoop-yarn-server-nodemanager` has one extant SpotBugs warning on trunk,
so Yetus votes `-1 spotbugs` on every PR whose module list includes
NodeManager, regardless of what the PR actually changes.
```
NP_NULL_ON_SOME_PATH_EXCEPTION
org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer
.ResourceLocalizationService$PublicLocalizer.run()
Value "assoc" dereferenced at line 997; null value at 986; known null at 987.
```
This is a false positive. `assoc` is only null on the path that logs
`"Localized unknown resource"` and returns early at line 989. The only source
of `ExecutionException` inside that `try` is `completed.get()` at line 991,
which follows the early return -- `FileUtil.getDU(File)` and
`EventHandler.handle(T)` declare no checked exceptions. SpotBugs models
exception paths conservatively and treats the handler as reachable from the
point where `assoc` is known null.
The warning is in fact already suppressed in
`hadoop-yarn/dev-support/findbugs-exclude.xml`, but the `<Method>` name went
stale:
- HADOOP-19670 (2025-11-21) made `PublicLocalizer` extend
`SubjectInheritingThread`, renaming `run()` to `work()`.
- YARN-11912 (2025-12-23) updated the filter from `run` to `work`, which
silenced the warning.
- The revert of HADOOP-19668/19670 (2026-07-06, #8568) restored `run()` in
the Java but left the filter saying `work`, so it now matches nothing and the
warning is live again.
This PR points the filter back at `run` and adds a comment recording why the
suppression exists, so a future rename is less likely to silently break it
again. No production code is touched.
### How was this patch tested?
```
mvn -pl
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager
\
-DskipTests test-compile spotbugs:spotbugs
```
Reading `target/spotbugsXml.xml` directly (the build exits 0 either way):
exactly one `BugInstance` before the change, matching the reported line
numbers, and zero after. It was the module's only warning.
### For code changes:
- [x] Does the title or this PR starts with the corresponding JIRA issue id
(e.g. 'HADOOP-17799. Your PR title ...')?
- [ ] Object storage: have the integration tests been executed and the
endpoint declared according to the connector-specific documentation?
- [ ] If adding new dependencies to the code, are these dependencies
licensed in a way that is compatible for inclusion under [ASF
2.0](http://www.apache.org/legal/resolved.html#category-a)?
- [ ] If applicable, have you updated the `LICENSE`, `LICENSE-binary`,
`NOTICE-binary` files?
🤖 Generated with [Claude Code](https://claude.com/claude-code)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]