epugh commented on code in PR #4008:
URL: https://github.com/apache/solr/pull/4008#discussion_r2659726581


##########
solr/core/src/java/org/apache/solr/handler/component/HttpShardHandlerFactory.java:
##########
@@ -224,7 +224,8 @@ private void initReplicaListTransformers(NamedList<?> 
routingConfig) {
   public void init(PluginInfo info) {
     StringBuilder sb = new StringBuilder();
     NamedList<?> args = info.initArgs;
-    this.scheme = getParameter(args, INIT_URL_SCHEME, null, sb);
+    // note: the sys prop is only used in testing
+    this.scheme = getParameter(args, INIT_URL_SCHEME, 
System.getProperty(INIT_URL_SCHEME), sb);

Review Comment:
   I totally believe you that this works, but it also just feels like a code 
smell..   why do we have to have a special magic property that is used in 
testing that is set up in this random method!  



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to