1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
/** |
4
|
|
|
* PHPPgAdmin v6.0.0-beta.33 |
5
|
|
|
*/ |
6
|
|
|
|
7
|
|
|
namespace PHPPgAdmin\Database; |
8
|
|
|
|
9
|
|
|
/** |
10
|
|
|
* @file |
11
|
|
|
* PostgreSQL 9.6 support |
12
|
|
|
*/ |
13
|
|
|
class Postgres96 extends Postgres |
14
|
|
|
{ |
15
|
|
|
public $major_version = 9.6; |
16
|
|
|
|
17
|
|
|
// Administration functions |
18
|
|
|
|
19
|
|
|
/** |
20
|
|
|
* Returns all available process information. |
21
|
|
|
* |
22
|
|
|
* @param $database (optional) Find only connections to specified database |
|
|
|
|
23
|
|
|
* |
24
|
|
|
* @return \ADORecordSet A recordset |
25
|
|
|
*/ |
26
|
|
|
public function getProcesses($database = null) |
27
|
|
|
{ |
28
|
|
|
if ($database === null) { |
29
|
|
|
$sql = "SELECT datid, datname, pid, usename, application_name, client_addr, state, wait_event_type, wait_event, state_change as query_start, |
30
|
|
|
CASE |
31
|
|
|
WHEN state='active' THEN query |
32
|
|
|
ELSE state |
33
|
|
|
END AS query |
34
|
|
|
FROM pg_catalog.pg_stat_activity |
35
|
|
|
ORDER BY datname, usename, pid"; |
36
|
|
|
} else { |
37
|
|
|
$this->clean($database); |
38
|
|
|
$sql = "SELECT datid, datname, pid, usename, application_name, client_addr, state, wait_event_type, wait_event, state_change as query_start, |
39
|
|
|
CASE |
40
|
|
|
WHEN state='active' THEN query |
41
|
|
|
ELSE state |
42
|
|
|
END AS query |
43
|
|
|
FROM pg_catalog.pg_stat_activity |
44
|
|
|
WHERE datname='{$database}' |
45
|
|
|
ORDER BY usename, pid"; |
46
|
|
|
} |
47
|
|
|
|
48
|
|
|
return $this->selectSet($sql); |
49
|
|
|
} |
50
|
|
|
|
51
|
|
|
public function hasUserSignals() |
52
|
|
|
{ |
53
|
|
|
return true; |
54
|
|
|
} |
55
|
|
|
} |
56
|
|
|
|
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths