mirror of
https://github.com/yacy/yacy_search_server.git
synced 2024-09-19 00:01:41 +02:00
set RootNodeFlag only if EmbeddedSolr is connected (as RootNodes may receive direct Solr queries)
This commit is contained in:
parent
2962f2b9e9
commit
38f46eb33d
|
@ -284,7 +284,8 @@ public final class Protocol {
|
||||||
} else {
|
} else {
|
||||||
final String myIP = result.get("yourip");
|
final String myIP = result.get("yourip");
|
||||||
final String properIP = Seed.isProperIP(myIP);
|
final String properIP = Seed.isProperIP(myIP);
|
||||||
mySeed.setFlagRootNode((mytype.equals(Seed.PEERTYPE_SENIOR) || mytype.equals(Seed.PEERTYPE_PRINCIPAL)) && responseTime < 1000 && Domains.isThisHostIP(myIP));
|
mySeed.setFlagRootNode((mytype.equals(Seed.PEERTYPE_SENIOR) || mytype.equals(Seed.PEERTYPE_PRINCIPAL)) && responseTime < 1000 && Domains.isThisHostIP(myIP) &&
|
||||||
|
Switchboard.getSwitchboard().index.fulltext().connectedLocalSolr()); // RootNode may receive direct Solr queries, set flag only if available
|
||||||
if ( properIP == null ) {
|
if ( properIP == null ) {
|
||||||
mySeed.setIP(myIP);
|
mySeed.setIP(myIP);
|
||||||
}
|
}
|
||||||
|
@ -1754,4 +1755,4 @@ public final class Protocol {
|
||||||
return parts;
|
return parts;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user