Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dev.icinga.com #8241] Take display_name into account when searching for host and service names #1315

Closed
icinga-migration opened this issue Jan 16, 2015 · 22 comments
Labels
area/monitoring Affects the monitoring module bug Something isn't working
Milestone

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/8241

Created by vaisov on 2015-01-16 09:58:40 +00:00

Assignee: elippmann
Status: Resolved (closed on 2015-05-21 12:10:03 +00:00)
Target Version: 2.0.0-rc1
Last Update: 2015-05-21 12:10:03 +00:00 (in Redmine)


Changesets

2015-05-19 12:01:18 +00:00 by aklimov 85dd496

Add parameter $searchColumns to ::filterQuery()

refs #8241

2015-05-19 12:04:23 +00:00 by aklimov a2b262e

Take display_name into account when searching for host and service names

refs #8241

2015-05-19 12:05:33 +00:00 by aklimov 75b004d

Merge branch 'bugfix/Take-display_name-into-account-when-searching-for-host-and-service-names-8241'

fixes #8241

2015-05-19 15:36:23 +00:00 by aklimov 3243f9a

Don't handle the case $this->searchColumns === null for actions in which ::setSearchColumns() is called

refs #8241

2015-05-19 15:36:23 +00:00 by aklimov 36713fb

Rename parameter $query of ::filterQuery() to $dataView

refs #8241

2015-05-19 15:36:24 +00:00 by aklimov cc050ed

Display an error notification rather than throwing an exception

refs #8241

2015-05-19 15:36:24 +00:00 by aklimov 2ed1d6c

Implement ::getSearchColumns()

refs #8241

2015-05-19 16:17:40 +00:00 by aklimov 6ba07b0

Implement and use Hostgroupsummary and Servicegroupsummary

refs #8241

2015-05-19 16:17:40 +00:00 by aklimov 93db1d1

Override ::getSearchColumns()

refs #8241

2015-05-19 16:17:41 +00:00 by aklimov 0b937c8

Get columns for FilterEditor::setSearchColumns() from DataView::getSearchColumns()

refs #8241

2015-05-20 08:43:54 +00:00 by aklimov 9b4f08e

Implement classes HostgroupsummaryQuery and ServicegroupsummaryQuery

Without this the Hostgroupsummary and Servicegroupsummary DataViews would not work

refs #8241

2015-05-20 13:29:45 +00:00 by elippmann 2493535

Revert "Implement classes HostgroupsummaryQuery and ServicegroupsummaryQuery"

This reverts commit 9b4f08eb433879f520dc7f93a4e205ae9bc631b5.

There's DataView::getQueryName() for this.

refs #8241

2015-05-20 13:50:06 +00:00 by elippmann 41e7239

monitoring: Use the groupsummary query for the host group summary view

refs #8241

2015-05-20 13:50:13 +00:00 by elippmann 5efbad3

monitoring: Don't sort the host group summary by service severity

refs #8241

2015-05-20 13:50:19 +00:00 by elippmann d379b27

monitoring: Hostgroupsummary must not extend Groupsummary which is subject to remove

refs #8241

2015-05-20 14:07:49 +00:00 by elippmann 2dc6d54

monitoring: Don't select unnecessary columns in the host group summary

refs #8241

2015-05-20 14:09:30 +00:00 by elippmann a9d6a94

monitoring: Use the groupsummary query for the service group summary view

refs #8241

2015-05-20 14:15:38 +00:00 by elippmann f9952cf

monitoring: Don't sort the service group summary by service severity

refs #8241

2015-05-20 14:16:21 +00:00 by elippmann 80b174f

monitoring: Servicegroupsummary must not extend Groupsummary which is subject to remove

refs #8241

2015-05-20 15:03:23 +00:00 by elippmann cfb819e

monitoring: Add missing column to the host group summary data view

refs #8241

2015-05-21 09:19:58 +00:00 by elippmann ce463d1

Reorder group summary query's columns by name

refs #8241

2015-05-21 09:23:55 +00:00 by elippmann bbed2cf

monitoring: Add column hosts_severity to the group summary query

refs #8241

2015-05-21 09:24:31 +00:00 by elippmann 37abc72

monitoring: Let the host group summary provide the column hosts_severity

refs #8241

2015-05-21 09:26:10 +00:00 by elippmann a52264a

monitoring: Sort by hosts_severity when sorting the host group summary by severity

refs #8241

2015-05-21 10:26:27 +00:00 by elippmann 58b3192

monitoring: Add sort rules to the host group summary

refs #8241

2015-05-21 10:36:05 +00:00 by elippmann 4b9f7eb

monitoring: Default to the sort rules of the host group summary

refs #8241

2015-05-21 10:37:53 +00:00 by elippmann 73eb8cc

monitoring: Add sort rule for total services to the host group summary

refs #8241

2015-05-21 10:38:20 +00:00 by elippmann 89bac33

monitoring: Fix sort control columns for the host group summary

refs #8241

2015-05-21 10:38:58 +00:00 by elippmann e7396ea

monitoring: Add services_severity to the service group summary data view

refs #8241

2015-05-21 10:41:29 +00:00 by elippmann 1a1f93d

monitoring: Add sort rules to the service group summary

refs #8241

2015-05-21 10:41:59 +00:00 by elippmann 0db7cfc

monitoring: Default to the sort rules of the service group summary

refs #8241

2015-05-21 10:42:53 +00:00 by elippmann e0c6ce5

monitoring: Fix sort control columns for the service group summary

refs #8241

2015-05-21 10:43:27 +00:00 by elippmann ad5ab16

monitoring: Drop the Groupsummary data view

We have Hostgroupsummary and Servicegroupsummary now.

refs #8241

2015-05-21 10:46:47 +00:00 by elippmann 0c72686

monitoring: Make display_name columns case insensitive

The display_name columns should be case insenstive because we now support them when searching.

refs #8241

2015-05-21 11:58:54 +00:00 by elippmann 57328aa

monitoring: Make host group and service group alias columns case insensitive

The alias columns should be case insenstive because we now support them when searching.

refs #8241

2015-05-21 12:04:04 +00:00 by elippmann c47465a

lib/filter: Fix check against unset search columns

refs #8241

2015-05-21 12:05:49 +00:00 by elippmann 47f21ee

Merge branch 'bugfix/Take-display_name-into-account-when-searching-for-host-and-service-names-8241'

fixes #8241

Relations:

@icinga-migration
Copy link
Author

Updated by vaisov on 2015-01-16 10:01:11 +00:00

I have service with values taken from loop:

apply Service for (name in [ "9003", "9004" ]) {
  import "generic-service"
  display_name = "uwsgi " + name
  check_command = "nrpe-arg"
  assign where "uwsgi" in host.groups
  vars.remote_nrpe_command = "check_local_port"
  vars.remote_nrpe_arguments = name
}

Also I have another check for uwsgi port 9006 which doesn't use loop's values:

apply Service "uwsgi 9006" {
  import "generic-service"
  display_name = "uwsgi 9006"
  check_command = "nrpe-arg"
  assign where match("staging-app*", host.name)
  ignore where host.name == "staging-app"
  vars.remote_nrpe_command = "check_local_port"
  vars.remote_nrpe_arguments = "9006"
}

When I try to search for 'uwsgi' in WebUI I get results only for port 9006.

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-19 16:32:47 +00:00

  • Category set to Monitoring
  • Status changed from New to Assigned
  • Assigned to set to elippmann
  • Target Version set to 2.0.0-beta2

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-20 14:55:21 +00:00

Hi,

Currently we only use the name1 and name2 columns for searching. In your example 9003 and 9004 are written to the name2 column. I'll add display_name as second search column. But you should fix your config because actually the name1 and name2 columns are intended to be the object names:

apply Service "uwsgi " for ...

Notice the "uswgi " prefix before the for loop. You may remove the display_name attribute then.

Cheers,
Eric

@icinga-migration
Copy link
Author

Updated by vaisov on 2015-01-20 15:32:13 +00:00

Hi,

does that mean that each object has to be described as in your example? Or it won't be needed after you'll add display_name as second search column? I want to avoid both this bug and this: https://dev.icinga.org/issues/8242, what is the best way to describe object to have proper sorting in ClassicUI and proper search in Web2?

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-20 15:51:51 +00:00

This is how to properly configure Icinga 2:

apply Service "uswgi " for (name in [ "9003", "9004" ]) {
  import "generic-service" 
  check_command = "nrpe-arg" 
  assign where "uwsgi" in host.groups
  vars.remote_nrpe_command = "check_local_port" 
  vars.remote_nrpe_arguments = name
}

@icinga-migration
Copy link
Author

Updated by vaisov on 2015-01-20 15:55:55 +00:00

So general advice would be to avoid display_name where possible?

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-20 16:40:52 +00:00

Hi,

vaisov wrote:

So general advice would be to avoid display_name where possible?

I would say, use display_name only where it makes sense. For example when using IP addresses or fully qualified domain names for host names, it is perfectly valid to define a display_name for those objects. Icinga Web 2 does not yet use the display_name attribute everywhere for display purposes though. But I'll implement that tomorrow. If you do not specify display_name then the object's name automatically maps to display_name.

Hope this helps.

Cheers,
Eric

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-21 08:39:50 +00:00

  • Subject changed from Search doesn't find values from 'for' loop to Take display_name into account when searching for host and service names

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-22 10:34:50 +00:00

  • Duplicates set to 6660

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-22 10:34:53 +00:00

  • Status changed from Assigned to Closed

Hi,

I'll close this one as duplicate for #8241.

Cheers,
Eric

@icinga-migration
Copy link
Author

Updated by tobiasvdk on 2015-01-22 10:42:35 +00:00

@lippser: Please re-open, you accidentally closed the wrong one.

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-01-22 11:38:25 +00:00

  • Status changed from Closed to Assigned

tobiasvdk wrote:

@lippser: Please re-open, you accidentally closed the wrong one.

Ooops. Thanks for the heads up :)

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-02-04 08:34:04 +00:00

  • Status changed from Assigned to New
  • Assigned to deleted elippmann
  • Target Version changed from 2.0.0-beta2 to Backlog

Hi,

This one didn't make into our second beta. But we'll fix it asap.

Cheers,
Eric

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-02-10 11:47:47 +00:00

  • Duplicated set to 8411

@icinga-migration
Copy link
Author

Updated by arcade on 2015-03-16 08:04:13 +00:00

This seems not to work anymore with the latest git pull.

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-03-30 10:26:58 +00:00

  • Target Version changed from Backlog to 2.0.0-rc1

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-05-19 09:05:51 +00:00

  • Status changed from New to Assigned
  • Assigned to set to aklimov

@icinga-migration
Copy link
Author

Updated by aklimov on 2015-05-19 12:10:03 +00:00

  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

Applied in changeset 75b004d.

@icinga-migration
Copy link
Author

Updated by aklimov on 2015-05-19 16:23:30 +00:00

  • Status changed from Resolved to Assigned
  • Done % changed from 100 to 0

@icinga-migration
Copy link
Author

Updated by aklimov on 2015-05-20 08:49:50 +00:00

  • Status changed from Assigned to Feedback
  • Assigned to changed from aklimov to elippmann

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-05-21 11:59:11 +00:00

  • Status changed from Feedback to Assigned

@icinga-migration
Copy link
Author

Updated by elippmann on 2015-05-21 12:10:03 +00:00

  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

Applied in changeset 47f21ee.

@icinga-migration icinga-migration added bug Something isn't working area/monitoring Affects the monitoring module labels Jan 17, 2017
@icinga-migration icinga-migration added this to the 2.0.0-rc1 milestone Jan 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/monitoring Affects the monitoring module bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant