Is connection manager in auto slave mode: it has `auto_slave` config, and connection is in automatic mode
@return boolean
320599
public function isAutoSlave()
    {
        return (!empty($this->configs['default']['options']['auto_slave'])) && isset($this->configs['slave']) && ($this->current === null);
    }
795440
public function isConnected()
    {
        try {
            return \is_resource($this->connection) && \ftp_rawlist($this->connection, $this->getRoot()) !== false;
        } catch (\ErrorException $e) {
            if (\strpos($e->getMessage(), 'ftp_rawlist') === false) {
                throw $e;
            }

            return false;
        }
    }
723610
public function isConnected()
    {
        $result = false;
        if($entity = $this->getIterator()->current()) {
            $result = $entity->isConnected();
        }

        return $result;
    }
337022
protected function _master()
    {
        if (null === $this->_master) {
            $this->_master = $this->_connection($this->_config_master);
        }
        return $this->_master;
    }
554438
public function disconnect()
    {
        if (!is_resource($this->connection)) {
            $this->connected = false;

            return true;
        }
        $this->connected = !fclose($this->connection);

        if (!$this->connected) {
            $this->connection = null;
        }

        return !$this->connected;
    }
1051210
public function isAutoInline($autoInline = null)
    {
        if ($autoInline !== null) {
            $this->autoInline = (bool) $autoInline;
        }

        return $this->autoInline;
    }
398312
public function isConfigured()
    {
        if (!empty($this->urlParts) && isset($this->solrMap[$this->className])) {
            return true;
        }
        return false;
    }
595715
public function useAssociatedPort() : bool
   {

      if ( null === $this->port )
      {
         return true;
      }

      switch ( $this->scheme )
      {

         case UrlScheme::HTTP:
            return ( $this->port === 80 );

         case UrlScheme::SSL:
            return ( $this->port === 443 );

         case UrlScheme::FTP:
            return ( $this->port === 21 );

         default :
            return false;

      }

   }
26204
public function isConnected()
    {
        return $this->synchronized(function ($self) {
            return $self->applicationState->equals(ApplicationStateKeys::get(ApplicationStateKeys::INITIALIZATION_SUCCESSFUL));
        }, $this);
    }
588682
public function getSlaveConnection()
    {
        if (null === $this->slaveConnection) {
            $this->slaveConnection = new \Redis();
            $this->slaveConnection->pconnect(
                $this->config['slave']['HOST'],
                $this->config['slave']['PORT']
            );
        }
        return $this->slaveConnection;
    }
1045849
public function is_connected() {
		$retval = false;
		if(isset($this->dbh) && count($this->dbh->getAvailableDrivers())) {
			$retval = true;
		}
		return($retval);
	}
1137837
public static function checkAutoGC()
    {
        if ((Daemon::$config->autogc->value > 0)
            && (Daemon::$process->counterGC > 0)
            && (Daemon::$process->counterGC >= Daemon::$config->autogc->value)
        ) {
            Daemon::$process->counterGC = 0;
            return true;
        }
        return false;
    }
723373
protected function configureConnectionManager(): void
    {
        if ($this->options['connection_manager']) {
            $this->connectionManager = $this->options['connection_manager'];
        } else {
            $class = $this->options['connection_manager_class'];
            $options = $this->options['connection_manager_options'];

            $this->connectionManager = new $class($this, $options);
        }

        $this->connectionManager->setLogger($this->logger);
    }
1284605
public function is_connection_ready() {
        if (!@$this->connection->set("ping", 'ping', 1)) {
            // Test the connection to the server.
            return false;
        }

        if ($this->isshared) {
            // There is a bug in libmemcached which means that it is not possible to purge the cache in a shared cache
            // configuration.
            // This issue currently affects:
            // - memcached 1.4.23+ with php-memcached <= 2.2.0
            // The following combinations are not affected:
            // - memcached <= 1.4.22 with any version of php-memcached
            // - any version of memcached with php-memcached >= 3.0.1


            // This check is cheapest as it does not involve connecting to the server at all.
            $safecombination = false;
            $extension = new ReflectionExtension('memcached');
            if ((version_compare($extension->getVersion(), '3.0.1') >= 0)) {
                // This is php-memcached version >= 3.0.1 which is a safe combination.
                $safecombination = true;
            }

            if (!$safecombination) {
                $allsafe = true;
                foreach ($this->connection->getVersion() as $version) {
                    $allsafe = $allsafe && (version_compare($version, '1.4.22') <= 0);
                }
                // All memcached servers connected are version <= 1.4.22 which is a safe combination.
                $safecombination = $allsafe;
            }

            if (!$safecombination) {
                // This is memcached 1.4.23+ and php-memcached < 3.0.1.
                // The issue may have been resolved in a subsequent update to any of the three libraries.
                // The only way to safely determine if the combination is safe is to call getAllKeys.
                // A safe combination will return an array, whilst an affected combination will return false.
                // This is the most expensive check.
                if (!is_array($this->connection->getAllKeys())) {
                    return false;
                }
            }
        }

        return true;
    }
981035
public function connect()
    {
        if ($this->isConnected) {
            return false;
        }

        $driverOptions = $this->params['driverOptions'] ?? [];
        $user          = $this->params['user'] ?? null;
        $password      = $this->params['password'] ?? null;

        $this->_conn       = $this->_driver->connect($this->params, $user, $password, $driverOptions);
        $this->isConnected = true;

        if ($this->autoCommit === false) {
            $this->beginTransaction();
        }

        if ($this->_eventManager->hasListeners(Events::postConnect)) {
            $eventArgs = new Event\ConnectionEventArgs($this);
            $this->_eventManager->dispatchEvent(Events::postConnect, $eventArgs);
        }

        return true;
    }
178268
private static function configEntityManager()
    {
        if (self::$entityManager) {
            return;
        }

        $isDevMode = cfg::htrFileConfigs()->devmode ?? false;
        $paths = [cfg::baseDir() . cfg::PATH_ENTITIES];

        // the connection configuration
        if ($isDevMode) {
            $dbParams = cfg::DATABASE_CONFIGS_DEV;
        } else {
            $dbParams = cfg::DATABASE_CONFIGS_PRD;
        }

        $cache = new ArrayCache();
        $reader = new AnnotationReader();
        $driver = new AnnotationDriver($reader, $paths);

        $config = Setup::createAnnotationMetadataConfiguration($paths, $isDevMode);
        $config->setMetadataCacheImpl($cache);
        $config->setQueryCacheImpl($cache);
        $config->setMetadataDriverImpl($driver);

        self::$entityManager = EntityManager::create($dbParams, $config);
    }
872893
public function isConfigured()
    {
        Logger::log('Checking configuration');
        $configured = (count($this->config) > 0);
        if ($configured) {
            foreach (static::$required as $required) {
                if (!array_key_exists($required, $this->config)) {
                    $configured = false;
                    break;
                }
            }
        }
        return $configured || $this->checkTryToSaveConfig() || self::isTest();
    }