[ 
https://issues.apache.org/jira/browse/SOLR-18167?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18089857#comment-18089857
 ] 

Jan Høydahl edited comment on SOLR-18167 at 6/18/26 8:01 AM:
-------------------------------------------------------------

This fix caused BATS tests to start failing, see 
[https://ci-builds.apache.org/job/Solr/job/Solr-TestIntegration-main/578/console]
{code:java}
not ok 99 deprecated system properties converted to modern properties # in 
43686 ms 
not ok 102 bootstrapping a configset # in 8898 ms {code}

Here is an LLM suggested fix

h2. Failure 1 — log message wording changed

Test #99 asserts the exact old log line ("You are passing in deprecated system 
property … and should upgrade to using … instead."). SOLR-18167 reworded this 
message in {{EnvUtils.applyDeprecatedPropertyMapping(...)}} to "Deprecated 
system property … has been replaced by …". The conversion itself still works; 
only the asserted string no longer matches.

*Fix hint:* either restore the original wording in {{EnvUtils}}, or update the 
assertion in {{test_start_solr.bats}} to the new wording. The reworded message 
reads fine, so updating the test is the lower-risk choice. Whichever is chosen, 
keep test and message in sync.

h2. Failure 2 — camelCase _legacy_ property names no longer convert

Test #102 starts Solr with {{-Dcollection.configName=techproducts}}. The new 
{{EnvUtils.findDeprecatedMappingKey(...)}} normalizes every incoming key 
through {{camelCaseToDotSeparated(...)}} _before_ looking it up in 
{{DEPRECATED_MAPPINGS}}. That map is keyed by the legacy name (see  
{{DeprecatedSystemPropertyMappings.properties}}, entry 
{{solr.configset.bootstrap.config.name=collection.configName}}). Normalization 
turns {{collection.configName}} into {{collection.config.name}}, which is not a 
map key, so the legacy property is silently dropped and  
{{solr.configset.bootstrap.config.name}} is never set — the configset is never 
bootstrapped and {{config_exists "techproducts"}} fails.

The same flaw affects any legacy key that contains camelCase; 
{{solr.disableFingerprint}} (from 
{{solr.index.replication.fingerprint.enabled=!solr.disableFingerprint}}) is the 
other one.

*Fix hint:* in {{findDeprecatedMappingKey}}, look up the raw incoming key first 
and only fall back to the camelCase-normalized form if the raw key is not 
found. That keeps camelCase legacy names matching while still resolving 
camelCase _new_ flags. {{applyDeprecatedPropertyMapping}} already reads the 
original value via the unmodified key, so no further change is needed there.

h2. Suggested regression coverage

Existing {{EnvUtilsTest}} cases only exercise camelCase _new_ flags. Add a case 
asserting that a camelCase _legacy_ key ({{collection.configName}}) is 
converted to its modern name ({{solr.configset.bootstrap.config.name}}).





was (Author: janhoy):
This fix caused BATS tests to start failing, see 
[https://ci-builds.apache.org/job/Solr/job/Solr-TestIntegration-main/578/console]
{code:java}
not ok 99 deprecated system properties converted to modern properties # in 
43686 ms 
not ok 102 bootstrapping a configset # in 8898 ms {code}

> Conversion of old to new property name not working
> --------------------------------------------------
>
>                 Key: SOLR-18167
>                 URL: https://issues.apache.org/jira/browse/SOLR-18167
>             Project: Solr
>          Issue Type: Bug
>    Affects Versions: 10.0
>            Reporter: Eric Pugh
>            Assignee: Eric Pugh
>            Priority: Blocker
>              Labels: pull-request-available
>             Fix For: 10.1
>
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> Upgrading Chorus from Solr 9 to 10.   I am concerned our EnvUtils conversion 
> isn't working.
>  
> "SOLR_OPTS=-Dsolr.auth.jwt.allowOutboundHttp=true" is used with jwt-auth:
> =>org.apache.solr.common.SolrException: wellKnownUrl is using http protocol. 
> HTTPS required for IDP communication. Please use SSL or start your nodes with 
> -Dsolr.auth.jwt.outbound.http.enabled=true to allow HTTP for test purposes.
>  
> at 
> org.apache.solr.security.jwt.JWTIssuerConfig.checkAllowOutboundHttpConnections(JWTIssuerConfig.java:594)
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to