[dev.icinga.com #1657] add livesearch to 'show hosts' #661
Comments
Updated by mfriedrich on 2011-06-15 21:21:19 +00:00 http://andreaslagerkvist.com/jquery/live-search/ and/or how thruk does it, but add also state coloring in the background. |
Updated by mfriedrich on 2011-11-04 08:12:06 +00:00
do some hacking together on osmc and see what might be doable. |
Updated by 6uellerBpanda on 2011-12-02 08:37:17 +00:00 if possible also show servicegroup,service,.. categorized. like in icinga-web. |
Updated by mfriedrich on 2012-04-03 14:03:43 +00:00
i don't think this can be done now. re-change if you think otherwise. |
Updated by mfriedrich on 2012-05-05 11:46:02 +00:00
|
Updated by mfriedrich on 2012-10-24 17:52:31 +00:00
when #3391 is in the making, this would be possible, but still, icinga2 will be a requirement. |
Updated by ricardo on 2013-02-20 23:31:45 +00:00 this might get somewhere soon. Let's see. |
Updated by mfriedrich on 2013-07-20 12:37:46 +00:00
|
Updated by kepi on 2013-09-22 13:47:41 +00:00
Here is patch against 'next' git branch with live search feature added. I didn't compile it - test needed. I may miss something as I created this on our server and put to git after that. Also I never worked with makefiles before so please fix my changes if needed. There is autocomplete.js.in file in html/js directory which uses Anyway live search working as supposed on our installation so please try and come back with suggestions. ricardo - cache is not implemented for now. I think it needs to be implemented on API's side to work as supposed. I tried to use slightly different approach than in draft. As "host / service" is really long. Hosts are simply list as first and then there is group of found services for every host. Sorry this take so long. |
Updated by ricardo on 2013-09-25 19:44:12 +00:00
Hi Kepi, thanks so much for your patch. It worked instantly. it lives for now in "feature/add-livesearch-to-menu-1657" Next steps to do are:
Cheers |
Updated by kepi on 2013-09-25 20:03:54 +00:00 As for JSON output, you will prepare some special CGI or do you count with using more api views for now? I'm still not sure about polling all data and local search. In fact you will drain much more resources with unnecessary polls - depending on use case. I.e. in my case I'm using search for about 5 % of my icinga uses. Most of time I'm using only TAC view. For me it will mean constant polling of API for no reason. By the way, I'm using search feature of json API now. Isn't it much faster and "cheaper" to use it this way instead of fetching all server and service data constantly? Local search can be done without any problem. Fixing right side problem should be easy too. Feel free to assign issue to me as long as we will decide about polling feature. |
Updated by ricardo on 2013-09-26 14:41:07 +00:00 in current "feature/add-livesearch-to-menu-1657" I added a special request param "livesearchdata". This returns JSON data to use only in live search. Initially I wanted to avoid that status.cgi gets request with every letter you type in. Because requesting status.cgi in big environments is very expensive. And as you said, caching the data locally and polling it every x seconds, sucks as well. How about this:
This way we most likely request status.cgi only once during search and user experience is the same. Now hostgroups and servicegroups get returned as well. Can we add them to the result list as well? Thanks Ricardo |
Updated by kepi on 2013-09-26 14:45:56 +00:00 Can you upload me some json example so I can try? I don't have any icinga test machine now so it will be faster for me this way. Your suggestion is good. It will be little harder to implement but more nice to servers. |
Updated by ricardo on 2013-09-26 17:33:00 +00:00
Of course. I added "livesearchdata.json" |
Updated by mfriedrich on 2013-09-26 17:42:05 +00:00
assigning to ricardo for now, i'm filtering for unassigned issues too. |
Updated by kepi on 2013-09-27 09:17:41 +00:00 Please assign to me as I'm not able to do it myself. |
Updated by ricardo on 2013-09-27 17:44:57 +00:00 It's not possible. I can't select your name as Assignee. |
Updated by mfriedrich on 2013-09-27 17:49:13 +00:00 redmine only allows to assign issues to roles with a defined state (i.e. an icinga padawan, or a developer). or the original author of the ticket (i.e. to ask for further input). as remarked via mail to ricardo, it would be reasonable to get you into the padawan program, but that's ricardo's decision being responsible here. |
Updated by kepi on 2013-09-29 19:51:45 +00:00
@dnsmichi: no need for now in this case. I don't have much time for hacking icinga unfortunately :) @ricardo: patch against feature/add-livesearch-to-menu-1657 is attached. It simply query server for first term entered (longer than 3 characters as you changed) and cache this result. When new term is entered, first 3 characters are compared to cache and if match is found, search is done locally. I also set expire for cache to 90 seconds (you can easily change value to whatever suits you best on line 9). Hostgroups and servergroups are included as well. I also found that you made some typo in url (in part prepare hosts data). There was status.cgi instead of extinfo, so I corrected thas to correct value. At least I suppose whole purpose of this search is to jump quickly to host detail. Width of query window is now smaller so it don't overlap. As before, I test it only locally so please test. |
Updated by ricardo on 2013-10-02 00:53:05 +00:00
Thank you so much Kepi. This is getting very close to what I imagined. submitted an update to "feature/add-livesearch-to-menu-1657"
do you like the changes? Any more ideas/suggestions? @dnsmichi: could this still make it into 1.10? @everybody: TEST IT and tell me what you think. thanks again. Cheers |
Updated by kepi on 2013-10-02 08:01:49 +00:00 I agree that in most cases you want to know how services are doing but you can see it directly in live search. This is why I supposed it is better to go to detail directly. Anyway now I'm in doubt and you are probably right :) so keep it the way you change it. Looking forward to see this on our servers :) |
Updated by mfriedrich on 2013-10-02 11:14:59 +00:00 i did not have the time to test the branch yet. feature freeze is tomorrow. let the team decide, write to the team list (with some additional screenshots in action). |
Updated by mfriedrich on 2013-10-02 23:34:00 +00:00
other than that, it's pretty fast :) |
Updated by elagon on 2013-10-03 08:56:25 +00:00 I think colors reflects statuses :) |
Updated by kepi on 2013-10-03 08:59:22 +00:00 About last issue: I think this behavior is pretty normal. You can trigger the popup again with down arrow. |
Updated by ricardo on 2013-10-03 11:34:44 +00:00 dnsmichi wrote:
it's the status of the object (OK/DOWN/CRITICAL/...) with the color schema of tac header
The shadow is irritating? I thought it is better to distinguish it from the rest of the menu behind it. Didn't want to make it bold or italic to prevent a line break if it's not necessary.
Yup, no problem.
will arrow down work for you? Otherwise you have to click somewhere else in menu to lose focus on the search box and to make the results disappear. |
Updated by ricardo on 2013-10-04 00:24:15 +00:00
in current "feature/add-livesearch-to-menu-1657"
how about this? Cheers |
Updated by mfriedrich on 2013-10-04 14:51:48 +00:00 ricardo wrote:
ah ok, my bad. i'm not really bringing the color into relation with a status, but that's obviously just my "i click on the total problems url in tac header only" behaviour. good idea.
not sure about that. the borders of the result dropdown could be made more emphasized, because you're right, the background contrast is awful with that mix of black/white/grey colors.
mouse event is perfectly fine like it behaves now:
i'd say this is pretty awesome for now :) any special changes to the filestructure, i.e. new folders for javascript files? packagers might wanna know. |
Updated by mfriedrich on 2013-10-04 14:51:57 +00:00
|
Updated by kepi on 2013-10-04 18:58:16 +00:00
I think maybe this could look more clean if you set white background and add something like color border to left side instead of full color background, something like this (only quick mockup): |
Updated by mfriedrich on 2013-10-04 20:16:46 +00:00 +1 for the removed background colors and only adding them on the left side. looks much more clean and focused. not sure about the header sections though - maybe that's too much the same of the original layout and may confuse users in their way of clicking or looking for information. |
Updated by kepi on 2013-10-04 20:37:02 +00:00 I was focusing only on normal lines, not headers. As I said, only quick mockup. Simply white background with bold font should be enough or something like that. |
Updated by ricardo on 2013-10-05 09:39:16 +00:00
no, only new files which are by default included in the jquery-ui package I really like Kepis approach. looks much more eye friendly. Unfortunately I don't have time to add this the next few days. Damn. |
Updated by mfriedrich on 2013-10-06 12:48:51 +00:00 since you're really wanting it in 1.10 you still got time for beautification (i guess that's how it's called) til beta time in ~1,5 weeks. feature freeze is only meant to take a cut and do not add any additional features, while working on the rest towards the final release - which i guess will be the case here, working on it. so please merge the feature branch into next, and then we'll see about some changes in layout and style. |
Updated by kepi on 2013-10-06 12:53:51 +00:00 ricardo, if there will be no other way, I can prepare those styles by the end of next week. I'll be on holiday but if this should stop including in next version I can find some time with computer there. |
Updated by mfriedrich on 2013-10-07 11:04:37 +00:00 i've rebased the branch against current 'next' - please keep that in mind when you fetch the latest changes. the rebased branch is now merged into next too. |
Updated by ricardo on 2013-10-08 00:00:31 +00:00 you are on holidays as well? just took some minutes to change the style. How do you like it now? Also added url encoding to hosts/services/hostgroups/servicegroups names. Used the rebased branch. |
Updated by mfriedrich on 2013-10-14 22:31:31 +00:00 latest and greatest is in 'next'. what's missing now? |
Updated by ricardo on 2013-10-15 20:00:28 +00:00
Was testing it in a live environment with some proper data. Works quite good. But we should recommend a modern browser to use it. There is a bit of javascript processing power needed in big environments. |
Updated by mfriedrich on 2014-12-08 09:32:34 +00:00
|
This issue has been migrated from Redmine: https://dev.icinga.com/issues/1657
Created by mfriedrich on 2011-06-15 21:19:29 +00:00
Assignee: ricardo
Status: Resolved (closed on 2013-10-15 20:00:28 +00:00)
Target Version: 1.10
Last Update: 2014-12-08 09:32:34 +00:00 (in Redmine)
would be cool for icinga classicui, and can happen with those many proof of concepts we already did. once and for all, this shouldn't happen based on the status.dat (but could be enabled throughout a cfg.cfg option - this might cause problems with heavy ajax polling and diskreads!) but use something like a core api using query filters to get the host list out of memory instead of parsing a file over and over.
Attachments
Changesets
2013-09-23 20:23:09 +00:00 by kepi 027b596c61553e46e48b192e537529c4a44b82f2
2013-09-25 19:06:34 +00:00 by ricardo 9ed61e9fed3161a082132e3b51a4aaca501c336e
2013-09-26 11:48:12 +00:00 by ricardo eba45779460295ddccf561d56d81d51220e77d36
2013-09-26 14:24:30 +00:00 by ricardo 79e1aee7878fa40876e07de2f517ffa6c85979bd
2013-09-30 16:47:28 +00:00 by kepi c769d44f34f1cf7a581bef8f6c5c3d00904a0558
2013-10-03 23:49:07 +00:00 by ricardo 5d000896d4bec0d518c32776c06b16083d506584
2013-10-07 11:00:06 +00:00 by kepi 93af651
2013-10-07 11:00:07 +00:00 by ricardo 33246d4
2013-10-07 11:00:07 +00:00 by ricardo e9db519
2013-10-07 11:00:07 +00:00 by ricardo a0e24b2
2013-10-07 11:00:07 +00:00 by kepi 0a4bad0
2013-10-07 11:00:50 +00:00 by ricardo cbdfd2c
2013-10-07 23:52:52 +00:00 by ricardo d1333be
2013-10-18 05:51:45 +00:00 by ricardo 6400160
2013-10-18 05:55:16 +00:00 by ricardo cc6f77e
Relations:
The text was updated successfully, but these errors were encountered: