Returns information about your current ServerQuery connection.

@return array
189471
public function whoami()
  {
    if($this->whoami === null)
    {
      $this->whoami = $this->request("whoami")->toList();
    }

    return $this->whoami;
  }
1109204
public function getQueries()
    {
        return array_merge(
            $this->getDropSequenceQueries(),
            $this->getDropViewQueries(),
            $this->getRenameTableQueries(),
            $this->getDropCheckQueries(),
            $this->getDropForeignKeyQueries(),
            $this->getDropIndexQueries(),
            $this->getDropPrimaryKeyQueries(),
            $this->getDropTableQueries(),
            $this->getDropColumnQueries(),
            $this->getAlterColumnQueries(),
            $this->getCreateColumnQueries(),
            $this->getCreateTableQueries(),
            $this->getCreatePrimaryKeyQueries(),
            $this->getCreateIndexQueries(),
            $this->getCreateForeignKeyQueries(),
            $this->getCreateCheckQueries(),
            $this->getCreateViewQueries(),
            $this->getCreateSequenceQueries(),
            $this->getRenameSchemaQueries()
        );
    }
190165
public function getServerInfo()
    {
        // init empty variables (can be filled if exec is allowed)
        $iMemTotal = $iMemFree = $sCpuModelName = $sCpuModel = $sCpuFreq = $iCpuCores = null;

        // fill, if exec is allowed
        if ($this->isExecAllowed()) {
            $iCpuAmnt = $this->_getCpuAmount();
            $iCpuMhz = $this->_getCpuMhz();
            $iBogo = $this->_getBogoMips();
            $iMemTotal = $this->_getMemoryTotal();
            $iMemFree = $this->_getMemoryFree();
            $sCpuModelName = $this->_getCpuModel();
            $sCpuModel = $iCpuAmnt . 'x ' . $sCpuModelName;
            $sCpuFreq = $iCpuMhz . ' MHz';

            // prevent "division by zero" error
            if ($iBogo && $iCpuMhz) {
                $iCpuCores = $iBogo / $iCpuMhz;
            }
        }

        $aServerInfo = [
            'Server OS'     => @php_uname('s'),
            'VM'            => $this->_getVirtualizationSystem(),
            'PHP'           => $this->_getPhpVersion(),
            'MySQL'         => $this->_getMySqlServerInfo(),
            'Apache'        => $this->_getApacheVersion(),
            'Disk total'    => $this->_getDiskTotalSpace(),
            'Disk free'     => $this->_getDiskFreeSpace(),
            'Memory total'  => $iMemTotal,
            'Memory free'   => $iMemFree,
            'CPU Model'     => $sCpuModel,
            'CPU frequency' => $sCpuFreq,
            'CPU cores'     => round($iCpuCores, 0),
        ];

        return $aServerInfo;
    }
173774
public function getInfo()
    {
        $this->hostIpinfo();
        $this->clientIpinfo();
        $this->getServerInfoSoftware();
        $this->serverInfoHardware();
        $this->uptime();
        $this->databaseInfo();

        return $this->results;
    }
916397
public function getServerPort()
    {
        return isset($this->swooleRequest->server['SERVER_PORT']) ? (int) $this->swooleRequest->server['SERVER_PORT'] : null;
    }
1370198
protected function _getQuery()
    {
        $sSLViewName = $this->_getViewName('oxselectlist');
        $sArtViewName = $this->_getViewName('oxarticles');
        $oDb = \OxidEsales\Eshop\Core\DatabaseProvider::getDb();

        $sArtId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('oxid');
        $sSynchArtId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('synchoxid');

        $sOxid = ($sArtId) ? $sArtId : $sSynchArtId;
        $sQ = "select oxparentid from {$sArtViewName} where oxid = " . $oDb->quote($sOxid) . " and oxparentid != '' ";
        $sQ .= "and (select count(oxobjectid) from oxobject2selectlist " .
               "where oxobjectid = " . $oDb->quote($sOxid) . ") = 0";
        // We force reading from master to prevent issues with slow replications or open transactions (see ESDEV-3804 and ESDEV-3822).
        $sParentId = \OxidEsales\Eshop\Core\DatabaseProvider::getMaster()->getOne($sQ);

        // all selectlists article is in
        $sQAdd = " from oxobject2selectlist left join {$sSLViewName} " .
                 "on {$sSLViewName}.oxid=oxobject2selectlist.oxselnid  " .
                 "where oxobject2selectlist.oxobjectid = " . $oDb->quote($sOxid) . " ";
        if ($sParentId) {
            $sQAdd .= "or oxobject2selectlist.oxobjectid = " . $oDb->quote($sParentId) . " ";
        }
        // all not assigned selectlists
        if ($sSynchArtId) {
            $sQAdd = " from {$sSLViewName}  " .
                     "where {$sSLViewName}.oxid not in ( select oxobject2selectlist.oxselnid {$sQAdd} ) ";
        }

        return $sQAdd;
    }
977805
public function getQueryParams()
    {
        if (isset($this->_queryParams)) {
            return $this->_queryParams;
        }

        if ($queryString = $this->getQueryString()) {
            $result = [];
            parse_str($queryString, $result);
            return $this->_queryParams = $result;
        }

        return $this->_queryParams;
    }
972251
public function getDescription()
    {
        if (!$this->queue) {
            return [
                'queue' => 'not set',
            ];
        }
        
        $connection = $this->queue->getConnection();
        
        return [
            'queue'     => $this->queue->getName(),
            'host'      => $connection->getHost(),
            'port'      => $connection->getPort(),
            'connected' => $connection->isConnected(),
            'class'     => __CLASS__,
        ];
    }
268605
protected function obtainConnectedServerList(): array
    {
        $serversList = $this->getServerList();
        $servers     = [];
        
        foreach ($serversList as $serverInfos) {
            $servers[] = $serverInfos['host'].':'.$serverInfos['port'];
        }
        
        return $servers;
    }
487739
function getServerParams()
    {
        if ($this->_server === null) {
            $params = PhpServer::_($this->httpMessage)->getServer();
            $this->_server = \Poirot\Std\cast($params)->toArray();
        }

        return $this->_server;
    }
567050
public function getServerInfos()
    {
        //====================================================================//
        // Init Result Array
        $response = new ArrayObject(array(), ArrayObject::ARRAY_AS_PROPS);

        //====================================================================//
        // Server Infos
        $response->ServerType = 'PHP';                              // INFO - Server Language Type
        $response->ServerVersion = PHP_VERSION;                     // INFO - Server Language Version
        $response->ProtocolVersion = SPL_PROTOCOL;                  // INFO - Server Protocal Version
        //====================================================================//
        // Server Infos
        $response->Self = Splash::input('PHP_SELF');                // INFO - Current Url
        $response->ServerAddress = Splash::input('SERVER_ADDR');    // INFO - Server IP Address
        // Read System Folder without symlinks
        $response->ServerRoot = realpath((string) Splash::input('DOCUMENT_ROOT'));
        $response->UserAgent = Splash::input('HTTP_USER_AGENT');    // INFO - Browser User Agent
        $response->WsMethod = Splash::configuration()->WsMethod;    // Current Splash WebService Component

        //====================================================================//
        // Server Urls
        //====================================================================//
        // CRITICAL - Server Host Name
        $response->ServerHost = $this->getServerName();

        //====================================================================//
        // Server IPv4 Address
        $response->ServerIP = Splash::input('SERVER_ADDR');

        //====================================================================//
        // Server WebService Path
        if (isset(Splash::configuration()->ServerPath)) {
            $response->ServerPath = Splash::configuration()->ServerPath;
        } else {
            $fullPath = dirname(__DIR__);
            $relPath = explode((string) $response->ServerRoot, $fullPath);
            if (is_array($relPath) && isset($relPath[1])) {
                $response->ServerPath = $relPath[1].'/soap.php';
            } else {
                $response->ServerPath = null;
            }
        }

        $response->setFlags(ArrayObject::STD_PROP_LIST);

        return $response;
    }
147170
public function getQueries()
    {
        return array_merge(
            $this->createNamespaceQueries,
            $this->createTableQueries,
            $this->createSequenceQueries,
            $this->createFkConstraintQueries
        );
    }
544780
public function serverInfo()
    {
        $url = $this->service_url . '/serverInfo';
        $data = $this->service->prepAndSend($url, array(200), 'GET', null, true, 'application/json', 'application/json');
        return json_decode($data, true);
    }
276607
public function getConnection()
    {
        $conn = mysqli_init();
        if ($this->encryption === true) {
            Logger::debug("Getting connection with encryption.");
            mysqli_ssl_set($conn, $this->sslKey, $this->sslCert, $this->sslCA, $this->sslCAPath, null);
            if ($this->port === null) {
                mysqli_real_connect($conn, $this->serverName, $this->username, $this->password, $this->databaseName);
            } else {
                mysqli_real_connect(
                    $conn,
                    $this->serverName,
                    $this->username,
                    $this->password,
                    $this->databaseName,
                    $this->port
                );
            }
        } elseif ($this->port === null) {
            mysqli_real_connect($conn, $this->serverName, $this->username, $this->password, $this->databaseName);
        } else {
            mysqli_real_connect(
                $conn,
                $this->serverName,
                $this->username,
                $this->password,
                $this->databaseName,
                $this->port
            );
        }
        return $conn;
    }
1266374
public function getConnectionHandlersAsArray()
    {

        // initialize the array for the connection handlers
        $connectionHandlers = array();

        // iterate over the connection handler nodes and sort them into an array
        /** @var \AppserverIo\Appserver\Core\Api\Node\ConnectionHandlerNode $connectionHandler */
        foreach ($this->getConnectionHandlers() as $connectionHandler) {
            $connectionHandlers[$connectionHandler->getUuid()] = $connectionHandler->getType();
        }

        // return the array
        return $connectionHandlers;
    }
942721
protected function _getMySqlServerInfo()
    {
        $aResult = \OxidEsales\Eshop\Core\DatabaseProvider::getDb(\OxidEsales\Eshop\Core\DatabaseProvider::FETCH_MODE_ASSOC)->getRow("SHOW VARIABLES LIKE 'version'");

        return $aResult['Value'];
    }
380899
protected function getStringConnectionsArray()
	{
		$processor = new AnydatasetFilenameProcessor("_db");
		$processor->UseFileFromAnyLanguage();
		$anydata = new AnyDataset($processor->FullQualifiedNameAndPath());
		$it = $anydata->getIterator();
		$ret = array();
		$ret[''] = '-- Default UsersAnydataSet --';
		while ($it->hasNext())
		{
			$sr = $it->moveNext();
			$ret[$sr->getField("dbname")] = $sr->getField("dbname");
		}

		return $ret;
	}