mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-28 16:24:04 +02:00
StatehistoryQuery, initial commit
This commit is contained in:
parent
07badc377e
commit
fbdfa7a59e
@ -0,0 +1,22 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Icinga\Monitoring\Backend\Ido\Query;
|
||||||
|
|
||||||
|
class StatehistoryQuery extends AbstractQuery
|
||||||
|
{
|
||||||
|
protected $columnMap = array(
|
||||||
|
'statehistory' => array(
|
||||||
|
'raw_timestamp' => 'state_time',
|
||||||
|
'timestamp' => 'UNIX_TIMESTAMP(state_time)',
|
||||||
|
'state_time' => 'state_time',
|
||||||
|
'object_id' => 'object_id',
|
||||||
|
'type' => "(CASE WHEN state_type = 1 THEN 'hard_state' ELSE 'soft_state' END)",
|
||||||
|
'state' => 'state',
|
||||||
|
'state_type' => 'state_type',
|
||||||
|
'output' => 'output',
|
||||||
|
'attempt' => 'current_check_attempt',
|
||||||
|
'max_attempts' => 'max_check_attempts',
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user