Skip to content

fix(job): pass the fess.suggest.* system properties on to the suggest creator - #4004

Open
marevol wants to merge 1 commit into
mainfrom
fix/forward-suggest-properties-to-child
Open

marevol wants to merge 1 commit into
mainfrom
fix/forward-suggest-properties-to-child

Conversation

@marevol

@marevol marevol commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

fess-suggest reads its settings for compound words and the fragment filter (fess.suggest.compound.*, fess.suggest.fragment.*, new in 15.10 with fess-suggest#107/#108) from system properties, in two JVMs: the web application, when it adds the words of the search logs, and the suggest creator process of the Suggest Indexer job, when it builds the index. The job forwarded only fess.config.*, fess.system.* and the matches of job.system.property.filter.pattern, so a -Dfess.suggest.* option in FESS_JAVA_OPTS changed only the search-log path, and the next job built the index the other way. The candidates of search words flipped with each job.

SuggestJob now forwards fess.suggest.* to the suggest creator the same way. Options in jvm.suggest.options come later on the command line, so they still override a forwarded value for the job.

The logged command is masked as before. A forwarded -Dfess.suggest.compound.break.tokens value shows as masked in the job log, because its name matches the default sensitive pattern (.*token.*); the process still receives the value.

UPGRADING.md describes the change of the suggest candidates in 15.10, when it takes effect (the 15.9 suggest index is served until the next Suggest Indexer run), that the bad words and elevate words carry over, and the three options that restore the 15.9 candidates.

Tests

  • ExecJobTest, SuggestJobTest (a forwarded fess.suggest.* option, and a fess.system.* secret still masked in the logged command).
  • Checked on a running build: with -Dfess.suggest.compound.enabled=false -Dfess.suggest.fragment.filter.enabled=false only in FESS_JAVA_OPTS, the suggest creator command line carries both options, the job builds no compound words, and a search-log candidate kept by the web application survives the next job. Without the change the job builds the compounds again and drops that candidate.

… creator

fess-suggest reads its settings (fess.suggest.compound.*, fess.suggest.fragment.*)
from system properties in both JVMs: the web application, when it adds the words
of the search logs, and the suggest creator process started by the Suggest
Indexer job. The job passed only fess.config.* and fess.system.* (and the
job.system.property.filter.pattern matches) on to that process, so a
-Dfess.suggest.* option in FESS_JAVA_OPTS changed only the search log path,
and the candidates built by the job did not follow it.

SuggestJob now also passes every fess.suggest.* property, in the same way as
fess.config.* and fess.system.*; the command written to the log is still masked.

UPGRADING.md describes the change of the suggest candidates in 15.10, that the
suggest index is rebuilt by the next Suggest Indexer run, and the three options
that restore the candidates of 15.9.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant