Свойство | Тип | Описание | |
---|---|---|---|
$criticalQueryThreshold | the threshold for determining whether the request has involved critical number of DB queries. If the number of queries exceeds this number, the execution is considered taking critical number of DB queries. | ||
$db | the name of the database component to use for executing (explain) queries | ||
$defaultFilter | the default filter to apply to the database queries. In the format of [ property => value ], for example: [ 'type' => 'SELECT' ] | ||
$defaultOrder | the default ordering of the database queries. In the format of [ property => sort direction ], for example: [ 'duration' => SORT_DESC ] |
Метод | Описание | |
---|---|---|
calculateTimings ( ) : array | Calculates given request profile timings. | |
canBeExplained ( string $type ) : boolean | Check if given query type can be explained. | |
getDb ( ) : |
Returns a reference to the DB component associated with the panel | |
getDetail ( ) | ||
getName ( ) | ||
getProfileLogs ( ) : array | Returns all profile logs of the current request for this panel. It includes categories such as: 'yii\db\Command::query', 'yii\db\Command::execute'. | |
getSummary ( ) | ||
getSummaryName ( ) : string | ||
getTypes ( ) : array | Returns array query types | |
init ( ) | ||
isQueryCountCritical ( integer $count ) : boolean | Check if given queries count is critical according settings. | |
save ( ) |
Метод | Описание | |
---|---|---|
getModels ( ) : array | Returns an array of models that represents logs of the current request. | |
getQueryType ( string $timing ) : string | Returns database query type. | |
getTotalQueryTime ( array $timings ) : integer | Returns total query time. | |
hasExplain ( ) : boolean |
public calculateTimings ( ) : array | ||
Результат | array | timings [token, category, timestamp, traces, nesting level, elapsed time] |
public static canBeExplained ( string $type ) : boolean | ||
$type | string | query type |
Результат | boolean |
public getDb ( ) : |
||
Результат |
public getProfileLogs ( ) : array | ||
Результат | array |
protected getQueryType ( string $timing ) : string | ||
$timing | string | timing procedure string |
Результат | string | query type such as select, insert, delete, etc. |
public getSummaryName ( ) : string | ||
Результат | string | short name of the panel, which will be use in summary. |
protected getTotalQueryTime ( array $timings ) : integer | ||
$timings | array | |
Результат | integer | total time |
protected hasExplain ( ) : boolean | ||
Результат | boolean | Whether the DB component has support for EXPLAIN queries |
public isQueryCountCritical ( integer $count ) : boolean | ||
$count | integer | queries count |
Результат | boolean |
public $criticalQueryThreshold |
public $db |
public $defaultFilter |