Property | Type | Description | |
---|---|---|---|
$emergencyMemory | string | Emergency memory that is used in the case of the memory limit error to handle error safely |
Method | Description | |
---|---|---|
AttachObserver ( |
Attach observer | |
FireEvent ( integer $farmid, AbstractServerEvent $event ) | File event in database | |
GenerateAPIKeys ( ) | ||
GenerateRandomKey ( integer $length = 128 ) : string | Generates random key of specified length | |
GenerateSecurePassword ( integer $length = 16, array $sets = null, array $enabledSets = null ) : string | Generates password that includes at least one symbols from each set: l - lower case characters u - upper case characters d - digits s - special characters | |
GenerateUID ( $short = false, $startWithLetter = false ) | ||
LaunchServer ( ServerCreateInfo $ServerCreateInfo = null, DBServer $DBServer = null, boolean $delayed = false, integer | array $reason, Scalr_Account_User | integer $user = null ) : DBServer | null | Launches server | |
ReconfigureObservers ( ) | Method for multiprocess scripts. We must recreate DB connection created in constructor | |
StoreEvent ( integer $farmid, AbstractServerEvent $event, $eventTime = null ) | Store event in database | |
camelize ( string $input ) : string | Camelizes string | |
config ( string $name ) : mixed | Gets config value | |
decamelize ( string $str ) : string | Decamelizes a string | |
errorHandler ( integer $errno, string $errstr, string $errfile, integer $errline ) | Scalr error handler | |
getAllHeaders ( ) : array | Get all http headers in camel-case form | |
getContainer ( ) : |
Gets DI container | |
getDb ( boolean $forceNewConnection = null ) : ADODB_mysqli | Gets an ADO Database Connection as singleton | |
initializeContainer ( ) | Performs preliminary initialization of the DI container | |
isAllowedAnalyticsOnHostedScalrAccount ( integer $accountId ) : boolean | Checks whether specified account is allowed to manage Cost centers and Projects on hosted scalr account | |
isHostedScalr ( ) : boolean | Checks whether current install is hosted scalr | |
logException ( Exception $e ) | Adds catchable exception to standart PHP error log | |
processHostDown ( DBServer $dbServer ) |
Method | Description | |
---|---|---|
setupObservers ( ) |
public static AttachObserver ( |
||
$observer |
public static GenerateRandomKey ( integer $length = 128 ) : string | ||
$length | integer | optional The length of the key |
return | string | Returns the random string of specified length |
public static GenerateSecurePassword ( integer $length = 16, array $sets = null, array $enabledSets = null ) : string | ||
$length | integer | optional Password length |
$sets | array | optional User (re-)defined characters sets |
$enabledSets | array | optional Names of enabled sets, if null — all sets are enabled |
return | string | Returns generated password |
public static GenerateUID ( $short = false, $startWithLetter = false ) |
public static LaunchServer ( ServerCreateInfo $ServerCreateInfo = null, DBServer $DBServer = null, boolean $delayed = false, integer | array $reason, Scalr_Account_User | integer $user = null ) : DBServer | null | ||
$ServerCreateInfo | ServerCreateInfo | optional The server create info |
$DBServer | DBServer | optional The DBServer object |
$delayed | boolean | optional |
$reason | integer | array | optional |
$user | Scalr_Account_User | integer | optional The Scalr_Account_User object or its unique identifier |
return | DBServer | null | Returns the DBServer object on cussess or null otherwise |
public static ReconfigureObservers ( ) |
public static StoreEvent ( integer $farmid, AbstractServerEvent $event, $eventTime = null ) | ||
$farmid | integer | |
$event | AbstractServerEvent |
public static decamelize ( string $str ) : string | ||
$str | string | A string |
return | string | Returns decamelized string |
public static getAllHeaders ( ) : array | ||
return | array |
public static getContainer ( ) : |
||
return |
public static initializeContainer ( ) |
public static isAllowedAnalyticsOnHostedScalrAccount ( integer $accountId ) : boolean | ||
$accountId | integer | Identifier of the client's account |
return | boolean | Returns true if it is allowed of false otherwise |
public static isHostedScalr ( ) : boolean | ||
return | boolean | Returns true if current install is a hosted Scalr |
public static logException ( Exception $e ) | ||
$e | Exception | The exception to log |
public static processHostDown ( DBServer $dbServer ) | ||
$dbServer | DBServer |
public static string $emergencyMemory | ||
return | string |