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

fragment_size doesn't work with quoted phrase #1072

Closed
yarkm13 opened this issue Jun 28, 2011 · 8 comments
Closed

fragment_size doesn't work with quoted phrase #1072

yarkm13 opened this issue Jun 28, 2011 · 8 comments
Assignees

Comments

@yarkm13
Copy link

yarkm13 commented Jun 28, 2011

I nave query with highlight like this: (Here is curl recreation https://gist.github.com/1032233 )
Look at issued result ( item4.description ) (you can see all doc also in _source ), and mapping.

if i supply query:
two words
item.description returns only 128 chars, as expected. But if
"two words"
it returns the same 128 chars and all remainder of that field. Bit strange.

ES (v 0.16.0)

Please tell, can I do the trick with highlight fields like ["item_.title", "item_.description"] in query fields?

I understand, it looks bit strange. I’m try to explain:
All my docs contains 10 items with title and description (and so on, not important). I need to have 1 match per field, so my first version with just array of items wont work. If i setup number_of_fragments to 1 it returns only 1 result for all 10 items. If i setup number_of_fragments to 0 it returns all description concatenated in 1 highlight. So solution is to make item1, item2 etc.
Is it best solution?

PS No any reaction on my 3 messages after first at mailing list. I believe this is a bug, so i created this issue.

@yarkm13
Copy link
Author

yarkm13 commented Jun 28, 2011

ES v 0.16.2 also vulnerable

@sirmarlo
Copy link

Has there been any progress with this? I too am seeing this issue and am wondering if there was a resolution.

@clintongormley
Copy link

This is still present in 0.90.0.RC1, I've rewritten the recreation into something runnable:

https://gist.github.com/clintongormley/5319822

At the bottom are two queries - one phrase query which shows the problem in item4.description, and one non-phrase query which shows expected behaviour.

@s1monw this looks like another lucene highlighter problem

@s1monw
Copy link
Contributor

s1monw commented Apr 5, 2013

LUCENE-4899 seems to fix this problem as well. At least the test I added does the right thing. I will keep this open until we upgraded to Lucene 4.3

@ghost ghost assigned s1monw Apr 5, 2013
@s1monw
Copy link
Contributor

s1monw commented Apr 27, 2013

Closed via 355f80a

@s1monw s1monw closed this as completed Apr 27, 2013
@MagmaRules
Copy link

I seem to be having the same problem in some cases: https://gist.github.com/MagmaRules/6028216
I'm running ES 0.90.1 (has lucene 4.3 in the lib).

@ajhalani
Copy link

I am still seeing the issue v0.90.5. Is this fix only for fastVectorHighlighter, not the plain highlighter?

@hdkeeper
Copy link

I'm experiencing the same problem. Elasticsearch 0.90.12.
Don't you know, will the issue be fixed somewhen?

martijnvg pushed a commit to martijnvg/elasticsearch that referenced this issue Jan 31, 2018
… same as their task (elastic#1072)

Changes persistent task serialization and forces params and status to have the same writeable name as the task itself.
martijnvg pushed a commit that referenced this issue Feb 5, 2018
… same as their task (#1072)

Changes persistent task serialization and forces params and status to have the same writeable name as the task itself.
emilykmarx pushed a commit to emilykmarx/elasticsearch that referenced this issue Dec 26, 2023
Clarify the field being used as source of the date formatting pattern in the index.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants