fix: drop the pitSegments override, which no longer overrides anything - #209
Merged
Merged
Conversation
The package rename in #208 was applied to every `org.opensearch.*` reference without checking that each type survived the fork. `PitSegmentsRequest` did not: fesen-httpclient's `Client` no longer declares `pitSegments`, so the rewritten import resolves to nothing and the method is an `@Override` of nothing. The PR's CI could not have caught this - it was red for the whole of its life because the forked fesen-httpclient was unpublished, so `fess-crawler-opensearch` never actually compiled there. Removed the method and the two imports it needed. Every other `org.codelibs.fesen.opensearch.*` name the module references was checked against the published jar's 2,491 classes; this was the only one missing.
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.
maindoes not compile since #208:What went wrong
#208 rewrote every
org.opensearch.*reference toorg.codelibs.fesen.opensearch.*.That rename was applied uniformly, but not every type survived the fork.
PitSegmentsRequestis one that did not, and fesen-httpclient'sClientno longerdeclares
pitSegments, soFesenClient.pitSegments(...)overrides nothing and itsimport resolves to nothing.
#208's CI could not have caught it. It was red from the day it opened because the
forked fesen-httpclient was not published yet, so
fess-crawler-opensearchneverreached javac there. Merging it was what first compiled the module.
Fix
The override is removed, along with the two imports it needed
(
IndicesSegmentResponsebecame unused with it). Nothing else referenced either.The rest of the module was checked the same way
Every
org.codelibs.fesen.opensearch.*name infess-crawler-opensearchwasmatched against the 2,491 classes in the published
fesen-httpclient-3.8.1-SNAPSHOTjar.
PitSegmentsRequestwas the only one missing — the one other flagged name,XContentFactory.jsonBuilder, is a static import of a member and its class ispresent.
Verification
mvn clean package— BUILD SUCCESS (was a compilation failure onmain).mvn clean install -DskipTests— BUILD SUCCESS.mvn test -pl fess-crawler-opensearch— 53 tests, 0 failures,FesenClientTest12 of them.