Highlighting attachments

I'm having an issue with getting attachments to highlight in ES. I think
it has something to do with my mapping, which you can find here:
http://pastebin.com/gs0mdUpE

What I'm confused about is, I thought that if I stored the document, it
would pull out the data and put it in the appropriate fields if I provided
the field property. This doesn't seem to be the case, as if I store the
document with my current mapping (which looks identical to other mappings
I've seen around the web), it just stores the content in the file property
of the _source and that's it. When I tried to add term_vector to the root
of the file property definition, it never took for some reason: only when I
add it to fields->file.

Can anyone shed some light on this/let me know if my mappings are wrong?
The search itself works great and returns what I need, I just can't seem
to get highlighting to work.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Hey Andrew,

Have a look at this gist: https://gist.github.com/dadoonet/3907010
(You need to adapt it somehow as it is a bit old).

It should help.

--
David :wink:
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

Le 6 août 2013 à 00:34, Andrew Soep siraris@gmail.com a écrit :

I'm having an issue with getting attachments to highlight in ES. I think it has something to do with my mapping, which you can find here: http://pastebin.com/gs0mdUpE

What I'm confused about is, I thought that if I stored the document, it would pull out the data and put it in the appropriate fields if I provided the field property. This doesn't seem to be the case, as if I store the document with my current mapping (which looks identical to other mappings I've seen around the web), it just stores the content in the file property of the _source and that's it. When I tried to add term_vector to the root of the file property definition, it never took for some reason: only when I add it to fields->file.

Can anyone shed some light on this/let me know if my mappings are wrong? The search itself works great and returns what I need, I just can't seem to get highlighting to work.

You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Hey David,

Thanks for the post. I saw a similar Gist before. I don't understand how
that's any different than my mapping? I store the file, it stores the
document, but it doesn't store it in the fields property, it just stores it
under "file" and doesn't seem to store any of the automatic attributes
under "fields".

On Monday, August 5, 2013 7:57:49 PM UTC-5, David Pilato wrote:

Hey Andrew,

Have a look at this gist: Test of attachments plugin · GitHub
(You need to adapt it somehow as it is a bit old).

It should help.

--
David :wink:
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

Le 6 août 2013 à 00:34, Andrew Soep <sir...@gmail.com <javascript:>> a
écrit :

I'm having an issue with getting attachments to highlight in ES. I think
it has something to do with my mapping, which you can find here:
"properties" : { "_content_type" : { "type" : "string" }, - Pastebin.com

What I'm confused about is, I thought that if I stored the document, it
would pull out the data and put it in the appropriate fields if I provided
the field property. This doesn't seem to be the case, as if I store the
document with my current mapping (which looks identical to other mappings
I've seen around the web), it just stores the content in the file property
of the _source and that's it. When I tried to add term_vector to the root
of the file property definition, it never took for some reason: only when I
add it to fields->file.

Can anyone shed some light on this/let me know if my mappings are wrong?
The search itself works great and returns what I need, I just can't seem
to get highlighting to work.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearc...@googlegroups.com <javascript:>.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.