fix: point Windows users at the option fess.in.bat actually reads for the engine URL - #3475
Merged
Merged
Conversation
… the engine URL When no search engine address is configured, Fess fails at startup with a message telling Windows users to set SEARCH_ENGINE_HTTP_URL in bin\fess.in.bat. fess.in.bat never reads that variable: only bin/fess.in.sh turns it into -Dfess.search_engine.http_address. On Windows the address comes from the -Dfess.search_engine.http_address line fess.in.bat carries (commented out), or from search_engine.http.url in fess_config.properties. The message now names SEARCH_ENGINE_HTTP_URL for bin/fess.in.sh only and the -Dfess.search_engine.http_address option for bin\fess.in.bat.
…ter install opensearch After `fess-setup install opensearch`, when bin/fess.in.sh will not find the installed OpenSearch on its own, the hint told users to set SEARCH_ENGINE_HTTP_URL and FESS_DICTIONARY_PATH in bin/fess.in.sh "(bin\fess.in.bat on Windows)". bin\fess.in.bat reads FESS_DICTIONARY_PATH but never SEARCH_ENGINE_HTTP_URL. The hint now names bin/fess.in.sh or the environment only, and adds a Windows note: set the URL with the -Dfess.search_engine.http_address option in bin\fess.in.bat, or with search_engine.http.url in fess_config.properties.
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.
Summary
When no search engine address is configured,
SearchEngineClient.open()fails startup with a message telling Windows users to setSEARCH_ENGINE_HTTP_URLinbin\fess.in.bat.fess.in.batnever reads that variable. Onlybin/fess.in.shturns it into-Dfess.search_engine.http_address. On Windows the address comes from the-Dfess.search_engine.http_addressline thatfess.in.batcarries (commented out, under "External opensearch cluster"), or fromsearch_engine.http.urlinfess_config.properties(read throughResourceUtil.getFesenHttpUrl()when the system property is absent).Changes
SEARCH_ENGINE_HTTP_URLforbin/fess.in.shonly and the-Dfess.search_engine.http_addressoption forbin\fess.in.bat. Thefess_config.propertieshint is unchanged.fess-setup install opensearch(whenbin/fess.in.shwill not find the installed OpenSearch) no longer tells Windows users to set both variables inbin\fess.in.bat. It namesbin/fess.in.shor the environment, and adds a Windows note:bin\fess.in.batreadsFESS_DICTIONARY_PATHbut notSEARCH_ENGINE_HTTP_URL, so set the URL with the-Dfess.search_engine.http_addressoption orsearch_engine.http.url.Testing
mvn test -Dtest=SearchEngineClientTest: 25 tests, 0 failures.install opensearchhint.mvn test -Dtest='org.codelibs.fess.setup.*Test,SearchEngineClientTest': 227 tests, 0 failures.