Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 16 additions & 9 deletions controllers/util/solr_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,10 @@ func GenerateStatefulSet(solrCloud *solr.SolrCloud, solrCloudStatus *solr.SolrCl
Name: "SOLR_HOST",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we get rid of this now? Since we have SOLR_HOST_ADVERTISE? Or will it be used by the CLI when we interact with it via other commands?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's for backward compatibility only. Depends if support for versions before introducing solr.host.advertise is necessary. If not then along with removal some tests and probeCommand in solr_security_util.go would require update.

Value: solrHostName,
},
{
Name: "SOLR_HOST_ADVERTISE",
Value: solrHostName,
},
{
Name: "SOLR_LOG_LEVEL",
Value: solrCloud.Spec.SolrLogLevel,
Expand Down Expand Up @@ -809,25 +813,28 @@ func createDefaultProbeHandlerForPath(probeScheme corev1.URIScheme, solrPodPort
const DefaultSolrXML = `<?xml version="1.0" encoding="UTF-8" ?>
<solr>
%s
<int name="maxBooleanClauses">${solr.max.booleanClauses:1024}</int>
<str name="sharedLib">${solr.sharedLib:}</str>
<str name="modules">${solr.modules:}</str>
<str name="allowPaths">${solr.security.allow.paths:}</str>
<str name="allowUrls">${solr.security.allow.urls:}</str>
<str name="hideStackTrace">${solr.hideStackTrace:false}</str>
<solrcloud>
<str name="host">${host:}</str>
<int name="hostPort">${solr.port.advertise:80}</int>
<str name="hostContext">${hostContext:solr}</str>
<bool name="genericCoreNodeNames">${genericCoreNodeNames:true}</bool>
<str name="host">${solr.host.advertise:}</str>
<int name="hostPort">${solr.port.advertise:0}</int>
<int name="zkClientTimeout">${zkClientTimeout:30000}</int>
<int name="distribUpdateSoTimeout">${distribUpdateSoTimeout:600000}</int>
<int name="distribUpdateConnTimeout">${distribUpdateConnTimeout:60000}</int>
<str name="zkCredentialsProvider">${zkCredentialsProvider:org.apache.solr.common.cloud.DefaultZkCredentialsProvider}</str>
<str name="zkACLProvider">${zkACLProvider:org.apache.solr.common.cloud.DefaultZkACLProvider}</str>
<str name="zkCredentialsInjector">${zkCredentialsInjector:org.apache.solr.common.cloud.DefaultZkCredentialsInjector}</str>
<int name="minStateByteLenForCompression">${minStateByteLenForCompression:-1}</int>
<str name="stateCompressor">${stateCompressor:org.apache.solr.common.util.ZLibCompressor}</str>
</solrcloud>
<shardHandlerFactory name="shardHandlerFactory"
class="HttpShardHandlerFactory">
<shardHandlerFactory name="shardHandlerFactory" class="HttpShardHandlerFactory">
<int name="socketTimeout">${socketTimeout:600000}</int>
<int name="connTimeout">${connTimeout:60000}</int>
</shardHandlerFactory>
<int name="maxBooleanClauses">${solr.max.booleanClauses:1024}</int>
<str name="allowPaths">${solr.allowPaths:}</str>
<metrics enabled="${metricsEnabled:true}"/>
%s
</solr>
`
Expand Down
Loading