Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 405990

Summary: Need explanation when an indexed search produces false match
Product: [ECD] Orion Reporter: Mark Macdonald <mamacdon>
Component: ClientAssignee: libing wang <libingw>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: john.arthorne, libingw
Version: 2.0   
Target Milestone: 3.0 M2   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Mark Macdonald CLA 2013-04-18 10:16:46 EDT
1. Go to orion.eclipse.org
2. Use the search toolbar to search for "editorTheme" in the orion client repo.
3. You will get about 19 matches. Most of these are false hits.
4. Try to expand one of the false hits. (For example, click the twistie beside "test-performance.html".)
5. The twistie expands, but nothing is there.

Anton and I found this confusing. I realize false matches are unavoidable with a fuzzy search, but we should present this explicitly with a message like "[search term] not found in file". 

In our current state, it gives the impression that the search is broken.
Comment 1 libing wang CLA 2013-04-19 07:57:30 EDT
Yes, the on-demand in-file search is already invoked anyway when the first time you click on twistie(or use right arrow key) to expand.
We also show the number of matches on the row of file if it's been ever expanded.
So the "[search term] not found in file" is just the replacement of "0 matches". Easy.

But what really bothered me is that editorTheme is hitting "editor/theme".
I know that sometimes it is fuzzy from Lucene for searching on special charactors, e.g. "-". But the fuzz pattern from this bug is brand new to me.
Comment 2 libing wang CLA 2013-04-19 08:05:42 EDT
BTW, if you use the advanced search with either regEx or caseSensitive on, you will hit the right results as it is forced to use crawling search, which is a little slower but 100% accurate.
I am even thinking about adding a flag in the advanced search popup, something like "accurate search". Then you can use the crawler anytime.
Comment 3 libing wang CLA 2013-04-19 08:58:01 EDT
fixed with http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=e748991f3d9873bc7f80e68ded3d45cca2551a94.

It also grey out(stale) the file item, with "No matches" message. If you use "expand all" action, which invokes all on-demand in-file search, you will immediately see all the false files.
Comment 4 libing wang CLA 2013-04-19 09:00:47 EDT
John, I fixed the bug but I am quite surprised how fuzzy lucene is. Please refer to comment 1.