3 final class PhabricatorMySQLSearchHost
4 extends PhabricatorSearchHost
{
6 public function setConfig($config) {
7 $this->setRoles(idx($config, 'roles',
8 array('read' => true, 'write' => true)));
12 public function getDisplayName() {
16 public function getStatusViewColumns() {
18 pht('Protocol') => 'mysql',
19 pht('Roles') => implode(', ', array_keys($this->getRoles())),
23 public function getProtocol() {
27 public function getHealthRecord() {
28 if (!$this->healthRecord
) {
29 $ref = PhabricatorDatabaseRef
::getMasterDatabaseRefForApplication(
31 $this->healthRecord
= $ref->getHealthRecord();
33 return $this->healthRecord
;
36 public function getConnectionStatus() {
37 PhabricatorDatabaseRef
::queryAll();
38 $ref = PhabricatorDatabaseRef
::getMasterDatabaseRefForApplication('search');
39 $status = $ref->getConnectionStatus();