Repository navigation
ftp: avoid final InterfaceAddress mocks in passive-mode tests - #8341
Open
greenc-FNAL wants to merge 1 commit into
Open
greenc-FNAL wants to merge 1 commit into
greenc-FNAL wants to merge 1 commit into
Conversation
greenc-FNAL
marked this pull request as ready for review
December 3, 2026 21:01
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
java.net.InterfaceAddressis final on Java 25. The configured Mockito mock maker therefore cannot create the interface-address mocks used by the passive-mode FTP tests, even though source compilation still targets Java 21.Modification
Add an
InetAddress-based supplier and protected adapter hook for passive address selection, and use real immutable address values in the tests. Preserve the existingsetAddressSupplierentry point, its null-clearing semantics, and delegation through the existing protected interface-address hook. Add regression coverage for those compatibility behaviors and close the EPSV test's passive handler reliably.Result
The focused FTP tests no longer depend on mocking
InterfaceAddress. Existing supplier callers and subclasses retain their adapter paths. This is an independent FTP compatibility/build-enabler PR, not a dependency-security upgrade.Validation and prerequisite
The sole signed topic commit is
ecd55c1c781e3c408d69f22a464bf8c736256b1c, based ondbb4fb0fe4236d25c8e993d92d3548d07f7bc005. Its patch is unchanged from the qualified FTP patch, as verified withgit range-diff.The local Maven 3.10 root reactor requires the separate frontend duplicate-dependency fix in #8339 before it can load the reactor model. This PR targets
master, deliberately excludes that POM patch, and remains draft pending the foundation and requalification after it lands.Qualification used only
masterat the stated SHA, the curator deduplication patch, and this FTP patch; it did not include the WebDAV fixture change or the dependency-security stack.Java 21:
Java 25 focused runtime qualification:
Both FTP classes passed on Java 21 and Java 25: 44 + 2 tests, zero failures, errors, or skips. This does not claim a full Java 25 reactor pass or a deployed FTP/GridFTP qualification. The legacy-adapter and cleared-supplier regression cases are included in the class counts.