Repository navigation
Conversation
…eral save The form mapping trims a text field and turns CRLF and CR into LF, while the value to be stored was compared with the raw -Dfess.system.<key> option or FESS_SYSTEM_<KEY> variable. A value with outer blanks or CR line breaks, such as a certificate ending with a line break, was therefore written to system.properties by an unchanged save and won over the option or variable from then on. The comparison now accepts the text as a form sends it back. Secrets and list choices, which are typed or chosen, are still compared as they are. The same applies to values that a save reformats: theme settings, the RAG chat permissions and labels, and the SPNEGO and Entra ID check boxes.
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.
A value that a setting gets from
-Dfess.system.<key>orFESS_SYSTEM_<KEY>was still copied intosystem.propertiesby a save of the General page that changed nothing, when it had outer blanks or CR line breaks (for examplesaml.idp.x509certgiven as a PEM that ends with a line break). The stored copy then wins, so a later change of the variable or option has no effect.Cause
The form mapping trims every text field and turns CRLF and CR into LF (except fields whose name ends with
password).FessPropcompared the value to be stored with the raw option or variable.Change
sso.type,storage.type,rag.llm.name,entraid.response.mode,fess.log.notification.level) are still compared as they are: they are typed or chosen, and retyping or choosing a value without a stray line break must be stored. The typed boolean and integer setters keep their own comparison for the same reason.theme.settings,rag.chat.permissionsandrag.chat.labels.entraid.use.dsare saved as booleans, so a variable such asTRUEis no longer copied astrue.Keys already in
system.propertiesare written as before.Behaviour to be aware of
For a text field, a value that differs from the option or variable only in outer blanks or line endings now counts as unchanged, on the screen and in
PUT /api/admin/general. The two cannot be told apart on the screen.Not changed
system.properties; remove the line to use the option or variable again.fess.log.notification.levelis read fromsystem.propertiesdirectly by the log notification appender.Tests
New cases in
AdminGeneralActionTest; four of them fail without the change, the others guard that edits, typed secrets and chosen values are still stored. Also checked by saving the General page in a browser against a running server with settings given by variables and an option: values were copied before the change and are not after it, and edited fields are stored.