Eric Lippmann
8300011c6f
Use requireVirtualTable()
2018-11-15 11:10:31 +01:00
Eric Lippmann
dda390b3d8
Require virtual table hosts
...
refs #3564
2018-11-14 10:22:17 +01:00
Johannes Meyer
dab9fea0d4
Merge pull request #3457 from Icinga/feature/proper-results-when-filtering-for-linked-objects-2934
...
Proper results when filtering for linked objects
2018-07-19 09:15:58 +02:00
Eric Lippmann
7624d99070
Use subquery filters for contacts if appropriate
...
refs #2934
2018-07-18 17:47:40 +02:00
Eric Lippmann
424f687f5d
Merge pull request #3532 from Icinga/bugfix/ido-check_interval
...
Fetch check_interval property of monitored objects, too
2018-07-18 16:32:37 +02:00
Eric Lippmann
c168ebfe3a
Fix subquery joins for host and service group views
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
3a434320e2
Fix subquery joins for negative filters
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
b7f0270a24
Use SELECT 1 for subquery filters
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
28e68f8f8a
Fix group base
2018-07-18 15:50:37 +02:00
Eric Lippmann
c3d25e1a59
Use subquery filters for service groups if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
61d325fa8a
Use subquery filters for host groups if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
a3ec0df7c5
Use subquery filters for service flapping history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
c4de14eb05
Use subquery filters for host flapping history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
1d4ee7824a
Use subquery filters for service comment history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
2ee0f99ed1
Use subquery filters for host comment history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
df7b5d663a
Use subquery filters for service downtime history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
0ca97d191f
Use subquery filters for host downtime history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
81b6b0129b
Use subquery filters for service state history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
bdb73ec06e
Use subquery filters for host state history if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
27f4fe82cd
Use subquery filters for service notifications if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
84c6055a17
Use subquery filters for service comments if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
a84cc40aa8
Use subquery filters for host notifications if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
db50d40068
Use subquery filters for host comments if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
271a1d72f1
Use subquery filters for contact groups if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
f7f02bdc8f
Use subquery filters for service downtimes if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Eric Lippmann
9f7b9edffe
Use subquery filters for host downtimes if appropriate
...
refs #2934
2018-07-18 15:50:37 +02:00
Johannes Meyer
186ef5a5a7
Use subquery filters for services if appropriate
...
refs #2934
Signed-off-by: Eric Lippmann <eric.lippmann@icinga.com>
2018-07-18 15:50:37 +02:00
Johannes Meyer
824fa870a2
Use subquery filters for hosts if appropriate
...
refs #2934
(EL): Alternative service group subquery filter:
```php
$this->joinVirtualTable('services');
$query->joinVirtualTable('members');
return ['sgm.service_object_id', 'so.object_id'];
```
But I think the committed solution is better.
Signed-off-by: Eric Lippmann <eric.lippmann@icinga.com>
2018-07-18 15:50:37 +02:00
Eric Lippmann
4b80b3e7ee
IdoQuery: Support & and != for subquery filters
...
refs #2934
2018-07-18 15:50:37 +02:00
Johannes Meyer
5c8cf64658
IdoQuery: Use subqueries to filter linked objects
...
refs #2934
Signed-off-by: Eric Lippmann <eric.lippmann@icinga.com>
2018-07-18 15:50:37 +02:00
Alexander A. Klimov
0b5620d2b5
Fetch check_interval property of monitored objects, too
2018-07-18 15:42:34 +02:00
Eric Lippmann
d5d336884c
Fix grouping in the new contact queries
...
refs #3088
2018-07-18 15:20:23 +02:00
Johannes Meyer
5befab6a2b
ContactQuery: Don't use a UNION query if not necessary
...
Speeds up the db's response time significantly in huge
environments.
refs #3088
Signed-off-by: Eric Lippmann <eric.lippmann@icinga.com>
2018-07-18 15:20:23 +02:00
Eric Lippmann
e684c6d18e
Split contact query into subqueries
...
One can't fetch host and service contacts with a reasonable single
query.
refs #3088
2018-07-18 15:20:23 +02:00
Eric Lippmann
ea722484b0
Introduce 'problems' columns for CLI usage
...
refs #3512
2018-07-09 16:10:07 +02:00
Johannes Meyer
4ec783b75e
IdoQuery: Use a dynamic collation when joining custom variables
...
refs #2508
2018-04-27 15:33:42 +02:00
Johannes Meyer
1c29b03b84
Revert "Merge pull request #3413 from Icinga/bugfix/filter-contacts-assigned-to-services-3088"
...
This reverts commit 33247237af
, reversing
changes made to 37aeb83cd9
.
refs #3436
2018-04-27 10:13:58 +02:00
Alexander A. Klimov
bbca113adc
IDO: treat contacts of services of hosts as direct contacts of the hosts
...
refs #3088
2018-04-06 15:16:36 +02:00
Alexander A. Klimov
4995df8336
Make host and service groups sortable by the members' severities
...
refs #3395
2018-04-04 10:05:27 +02:00
Johannes Meyer
b07e4b409f
EventHistory: Drop obsolete SUM aggregates
...
Not used anywhere and not working for a long time already,
at least as filter columns.
refs #2860
2018-01-17 12:41:10 +01:00
lippserd
6abb91421a
Merge pull request #3220 from Icinga/fix/filter-by-custom-variables
...
Fix filter by host custom variables
2018-01-11 11:40:22 +01:00
Alexander A. Klimov
196cdbe4af
Implement event history detail view
...
refs #3191
2018-01-09 13:04:06 +01:00
Eric Lippmann
93ec798c6b
Ido: Map h.host_object_id to s.host_object_id in the ServicegroupQuery
...
This is required to make filters work which filter by host custom variables without using any host related table.
2017-12-18 10:35:16 +01:00
Eric Lippmann
b1f7923711
Ido: Allow custom variables to be mapped
...
If you filter by host custom variables and the query does not have the services table joined,
our query implementation calls the joinHosts method. Then, the column for the JOIN ON condition is
automatically set to h.host_object_id.
But it may be required by the query to call joinServices and use s.host_object_id instead of
h.host_object_id because the query does not use any host related table at all.
This is now possible when h.host_object_id is mapped to s.host_object_id:
class ServicesRelatedQuery
{
protected $columnMap = array(
'hosts' => array(
'h.host_object_id' => 's.host_object_id'
)
);
protected function joinHosts()
{
$this->requireVirtualTable('services');
}
}
2017-12-18 10:23:45 +01:00
lippserd
a5bf9e0175
Merge pull request #3029 from Icinga/bugfix/empty-host-and-service-groups-not-shown-2796
...
Bugfix/empty host and service groups not shown 2796
2017-11-27 14:24:11 +01:00
Eric Lippmann
d11519ac49
pogsql: Group by custom variables when querying them
...
Custom variables added via the URL parameters addColumns or sort must be added to the GROUP BY list when using PostgreSQL.
Credits to @nbuchwitz who came up with the initial fix for this.
refs #1873
2017-11-16 09:20:22 +01:00
Johannes Meyer
23066d2cc4
ServicegroupQuery: Use left joins instead of inner joins
...
refs #2796
2017-11-09 09:42:46 +01:00
Johannes Meyer
4ef085bdcd
HostgroupQuery: Use left joins instead of inner joins
...
refs #2796
2017-11-09 09:42:46 +01:00
Eric Lippmann
121fdaadb0
Allow to search for host and servicegroups by their case insensitive names too
...
refs #2971
2017-11-08 15:40:43 +01:00
Eric Lippmann
8de0b80f9e
Fix contact group member count
...
fixes #2837
2017-10-05 14:35:15 +02:00