mirror of https://github.com/apache/lucene.git
SOLR-9386: Move default clientPort specification to before calling QuorumPeerConfig.parseProperties(), which requires that clientPort be specified.
This commit is contained in:
parent
b705217bec
commit
8c11f81a95
|
@ -85,10 +85,10 @@ public class SolrZkServer {
|
|||
try {
|
||||
props = SolrZkServerProps.getProperties(confHome + '/' + "zoo.cfg");
|
||||
SolrZkServerProps.injectServers(props, zkRun, zkHost);
|
||||
zkProps.parseProperties(props);
|
||||
if (zkProps.getClientPortAddress() == null) {
|
||||
zkProps.setClientPort(solrPort + 1000);
|
||||
if (props.getProperty("clientPort") == null) {
|
||||
props.setProperty("clientPort", Integer.toString(solrPort + 1000));
|
||||
}
|
||||
zkProps.parseProperties(props);
|
||||
} catch (QuorumPeerConfig.ConfigException | IOException e) {
|
||||
if (zkRun != null)
|
||||
throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, e);
|
||||
|
|
Loading…
Reference in New Issue