Page MenuHomePhorge
Diviner Tech Docs PhabricatorElasticFulltextStorageEngine

class PhabricatorElasticFulltextStorageEngine
Phorge Technical Documentation (Search)

This class is not documented.

Methods

public function __get($name)
Inherited

This method is not documented.
Parameters
$name
Return
wild

public function __set($name, $value)
Inherited

This method is not documented.
Parameters
$name
$value
Return
wild

public function current()
Inherited

This method is not documented.
Return
wild

public function key()
Inherited

This method is not documented.
Return
wild

public function next()
Inherited

This method is not documented.
Return
wild

public function rewind()
Inherited

This method is not documented.
Return
wild

public function valid()
Inherited

This method is not documented.
Return
wild

private function throwOnAttemptedIteration()
Inherited

This method is not documented.
Return
wild

public function getPhobjectClassConstant($key, $byte_limit)
Inherited

Phobject

Read the value of a class constant.

This is the same as just typing self::CONSTANTNAME, but throws a more useful message if the constant is not defined and allows the constant to be limited to a maximum length.

Parameters
string$keyName of the constant.
int|null$byte_limitMaximum number of bytes permitted in the value.
Return
stringValue of the constant.

public function getHosts()
Inherited

This method is not documented.
Return
wild

public function setService($service)

This method is not documented.
Parameters
PhabricatorSearchService$service
Return
wild

public function getService()
Inherited

This method is not documented.
Return
PhabricatorSearchService

public function getHostType()

PhabricatorFulltextStorageEngine

Implementations must return a prototype host instance which is cloned by the PhabricatorSearchService infrastructure to configure each engine.

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Return
PhabricatorSearchHost

public function getEngineIdentifier()

PhabricatorFulltextStorageEngine

Return a unique, nonempty string which identifies this storage engine.

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Return
stringUnique string for this engine, max length 32.

public function reindexAbstractDocument($doc)

PhabricatorFulltextStorageEngine

Update the index for an abstract document.

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Parameters
PhabricatorSearchAbstractDocument$documentDocument to update.
Return
void

public function executeSearch($query)

PhabricatorFulltextStorageEngine

Execute a search query.

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Parameters
PhabricatorSavedQuery$queryA query to execute.
Return
listA list of matching PHIDs.

public function indexExists($host)

PhabricatorFulltextStorageEngine

Does the search index exist?

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Return
bool

public function getIndexStats($host)

PhabricatorFulltextStorageEngine

Implementations should override this method to return a dictionary of stats which are suitable for display in the admin UI.

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Return
wild

public function indexIsSane($host)

PhabricatorFulltextStorageEngine

Is the index in a usable state?

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Return
bool

public function initIndex()

PhabricatorFulltextStorageEngine

Do any sort of setup for the search index.

PhabricatorElasticFulltextStorageEngine
This method is not documented.
Return
void

public function getFulltextTokens()
Inherited

This method is not documented.
Return
wild

public function getTimestampField()

This method is not documented.
Return
wild

public function getTextFieldType()

This method is not documented.
Return
wild

public function getHostForRead()

This method is not documented.
Return
wild

public function getHostForWrite()

This method is not documented.
Return
wild

public function setTimeout($timeout)

This method is not documented.
Parameters
$timeout
Return
wild

public function getTimeout()

This method is not documented.
Return
wild

public function getTypeConstants($class)

This method is not documented.
Parameters
$class
Return
wild

private function buildSpec($query)

This method is not documented.
Parameters
PhabricatorSavedQuery$query
Return
wild

private function getIndexConfiguration()

This method is not documented.
Return
wild

private function check($actual, $required, $path)

Recursively check if two Elasticsearch configuration arrays are equal

Parameters
$actual$actual
$required$requiredarray
$path
Return
bool

private static function normalizeConfigValue($value)

Normalize a config value for comparison. Elasticsearch accepts all kinds of config values but it tends to throw back 'true' for true and 'false' for false so we normalize everything. Sometimes, oddly, it'll throw back false for false....

Parameters
mixed$valueconfig value
Return
mixedvalue normalized

private function executeRequest($host, $path, $data, $method)

This method is not documented.
Parameters
PhabricatorElasticsearchHost$host
$path
array$data
$method
Return
wild