CirrusSearch
Elasticsearch-powered search for MediaWiki
Loading...
Searching...
No Matches
CirrusSearch\ClusterSettings Class Reference

Handles resolving configuration variables into specific settings for a specific cluster. More...

Public Member Functions

 __construct (SearchConfig $config, $cluster)
 
 getName ()
 
 isPrivateCluster ()
 
 getShardCount ( $indexSuffix)
 
 getReplicaCount ( $indexSuffix)
 
 getMaxShardsPerNode ( $indexSuffix)
 
 isIsolated ()
 
 getElasticaWritePartitionCount ()
 
 getConnectTimeout ()
 

Protected Attributes

 $config
 
 $cluster
 

Detailed Description

Handles resolving configuration variables into specific settings for a specific cluster.

Constructor & Destructor Documentation

◆ __construct()

CirrusSearch\ClusterSettings::__construct ( SearchConfig $config,
$cluster )
Parameters
SearchConfig$config
string$cluster

Member Function Documentation

◆ getConnectTimeout()

CirrusSearch\ClusterSettings::getConnectTimeout ( )
Returns
int Connect timeout to use when initializing connection. Fallback to 0 (300 sec) if not specified in cirrus config.

◆ getElasticaWritePartitionCount()

CirrusSearch\ClusterSettings::getElasticaWritePartitionCount ( )
Returns
int Number of partitions the ElasticaWrite job can be split into

◆ getMaxShardsPerNode()

CirrusSearch\ClusterSettings::getMaxShardsPerNode ( $indexSuffix)
Parameters
string$indexSuffix
Returns
int Number of shards per node, or 'unlimited'.

◆ getReplicaCount()

CirrusSearch\ClusterSettings::getReplicaCount ( $indexSuffix)
Parameters
string$indexSuffix
Returns
string Number of replicas Elasticsearch can expand or contract to in the format of '0-2' for the minimum and maximum number of replicas. May also be the string 'false' when replicas are disabled.

◆ getShardCount()

CirrusSearch\ClusterSettings::getShardCount ( $indexSuffix)
Parameters
string$indexSuffix
Returns
int Number of shards the index should have

◆ isIsolated()

CirrusSearch\ClusterSettings::isIsolated ( )
Returns
bool True when write isolation is configured for this cluster.

◆ isPrivateCluster()

CirrusSearch\ClusterSettings::isPrivateCluster ( )
Returns
bool True when the cluster is allowed to contain private indices

The documentation for this class was generated from the following file: