Return-Path: X-Original-To: apmail-lucene-solr-user-archive@minotaur.apache.org Delivered-To: apmail-lucene-solr-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id F3B0618480 for ; Wed, 12 Aug 2015 15:28:26 +0000 (UTC) Received: (qmail 8488 invoked by uid 500); 12 Aug 2015 15:28:13 -0000 Delivered-To: apmail-lucene-solr-user-archive@lucene.apache.org Received: (qmail 8418 invoked by uid 500); 12 Aug 2015 15:28:12 -0000 Mailing-List: contact solr-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-user@lucene.apache.org Delivered-To: mailing list solr-user@lucene.apache.org Received: (qmail 8406 invoked by uid 99); 12 Aug 2015 15:28:12 -0000 Received: from Unknown (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Aug 2015 15:28:12 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 01EBF1A9CF3 for ; Wed, 12 Aug 2015 15:28:12 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.401 X-Spam-Level: ** X-Spam-Status: No, score=2.401 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RDNS_NONE=2.5, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id BLgLbOnxe3ff for ; Wed, 12 Aug 2015 15:27:58 +0000 (UTC) Received: from spamd1-us-west.apache.org (unknown [209.188.14.142]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with ESMTP id 4CB5642BAC for ; Wed, 12 Aug 2015 15:27:58 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 0CFFCDC95E for ; Wed, 12 Aug 2015 15:27:58 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id d-JVhdqFGMPl for ; Wed, 12 Aug 2015 15:27:48 +0000 (UTC) Received: from spamd1-us-west.apache.org (unknown [209.188.14.142]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTP id 760A82652D for ; Wed, 12 Aug 2015 15:27:48 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 414A6DC94A for ; Wed, 12 Aug 2015 15:27:48 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id 0FCRl-2Wjavq for ; Wed, 12 Aug 2015 15:27:34 +0000 (UTC) Received: from spamd1-us-west.apache.org (unknown [209.188.14.142]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with ESMTP id 7E72642BB4 for ; Wed, 12 Aug 2015 15:27:34 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 3FCEEDC94A for ; Wed, 12 Aug 2015 15:27:34 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id 7tQfYuley4Ox for ; Wed, 12 Aug 2015 15:27:19 +0000 (UTC) Received: from mail-ig0-f176.google.com (mail-ig0-f176.google.com [209.85.213.176]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with ESMTPS id B585642BC9 for ; Wed, 12 Aug 2015 15:27:19 +0000 (UTC) Received: by igbpg9 with SMTP id pg9so114378244igb.0 for ; Wed, 12 Aug 2015 08:27:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=g8a/EkGT2En+0oT6o0ZYDPYUFhjJUHrseUE2eLXNj+8=; b=xG43zB5lKvoJO5dWgbWLxVkDxdYH0ngjeAFJL6LbmMkGBAaBXnp4UvpHzURV0RDD+U dpvVv8oscInlK8AYOHMnr1H9wGG6ut+sJwptqa+7Ebny2VyL/JwNwMV6NVZOcNAJ1iAt LN5K64SysOLootKXd0iIjAg/dzl8FVCKFk5tD0O0EXgFax9zfD2/Q1z4Nuh1mk2iOgPn PqPKdLQBl9cG+8hGFIhgEpGoCaOScouY9WvOAn9x2Suah09FHjDa6KOQlx0oR/yoPgHL b3aHVSNvgAO7lYRpoaTTNneWwJpT8qIIFmoBhj4Xm+TziiV+hwtxmUhhLC+BJiZeLmSv rVRQ== MIME-Version: 1.0 X-Received: by 10.50.41.67 with SMTP id d3mr23915617igl.57.1439393239341; Wed, 12 Aug 2015 08:27:19 -0700 (PDT) Received: by 10.107.53.201 with HTTP; Wed, 12 Aug 2015 08:27:19 -0700 (PDT) In-Reply-To: <55CB5F65.5000806@tnstaafl.net> References: <566901b4e7234461866e02b03dec0589@SJCPEXCH05.corp.avanade.org> <389050a871f24eff92a79b4eadcaf3a3@SJCPEXCH05.corp.avanade.org> <55CA46B6.9000107@tnstaafl.net> <3BA01A6CF46D6640B83AC1D1B5D16532FCBAAB@EXMBX01L-CRP-03.webmdhealth.net> <55CA9B2E.60102@tnstaafl.net> <79487E45-F2F7-4CF7-A436-3CF222AB8ACA@gmail.com> <55CB3E81.40901@tnstaafl.net> <55CB5627.8030808@tnstaafl.net> <55CB5F65.5000806@tnstaafl.net> Date: Wed, 12 Aug 2015 08:27:19 -0700 Message-ID: Subject: Re: Highlighting, all matches show empty {} From: Erick Erickson To: solr-user@lucene.apache.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Well, the example you just showed shouldn't show any highlighting. Your que= ry is q=3Dconcord so it's trying to highlight "concord" which isn't in any of your documents. hl.q can be used to highlight something other than your q parameter. I did notice in some of your other examples that you seemed to be searching= for terms that were in the fields so I suspect this isn't really your root problem though. do note that fields _must_ be stored to have highlighting work. Is it possible that your matches are on fields that aren't stored? Let's build it up slowly though, try searching on one term in one field that you _know_ is stored and see if you get anything back. While the query with hl.fl=3D* and fl=3Dfield1, field2, should be fine, let's start as simply as possible and work up maybe? Best, Erick On Wed, Aug 12, 2015 at 7:59 AM, Scott Derrick wrote: > I think the highlighter is actually running, but I'm not getting the > results?? > > with this request > > http://localhost:8983/solr/mbepp/select?q=3Dconcord&fl=3Daccession%2C+tit= le%2C+author%2C+date&wt=3Djson&indent=3Dtrue&hl=3Dtrue&hl.fl=3D* > > > I get this response > > { > "responseHeader":{ > "status":0, > "QTime":3, > "params":{ > "q":"concord", > "hl":"true", > "indent":"true", > "fl":"accession, title, author, date", > "hl.fl":"*", > "wt":"json"}}, > "response":{"numFound":3,"start":0,"docs":[ > { > "date":"1890-02-26", > "author":"Mary Baker Eddy", > "accession":"L13943", > "title":["Mary Baker Eddy to Joseph E. Adams,"]}, > { > "date":"1896-01-13", > "author":"Mary Baker Eddy", > "accession":"L03453", > "title":["Mary Baker Eddy to Ira O. Knapp,"]}, > { > "date":"1902-06-15", > "author":"Mary Baker Eddy", > "accession":"A10145", > "title":["Message of the Pastor Emeritus to The First Church of > Christ, Scientist, Boston, Mass., June 15, 1902"]}] > }, > "highlighting":{ > > "/home/scott/workspace/mbel-work/tei2html/build/web/L13943/L13943.html":{= }, > > "/home/scott/workspace/mbel-work/tei2html/build/web/L03453/L03453.html":{= }, > > "/home/scott/workspace/mbel-work/tei2html/build/web/A10145/A10145.html":{= }}} > > When I ran the request. > In the admin plubins/Stats I set "Watch Changes" before processing the > request. Highlighting showed 2 changes, the gapFragmenter and HTMLFormat= ter > > here are the reported changes > > org.apache.solr.highlight.GapFragmenter > class: org.apache.solr.highlight.GapFragmenter > version: 5.2.1 > description: GapFragmenter > stats: requests: Was: 117, Now: 156, Delta: 39 > > org.apache.solr.highlight.HtmlFormatter > class: org.apache.solr.highlight.HtmlFormatter > version:5.2.1 > description:HtmlFormatter > stats: requests: Was: 117, Now: 156, Delta: 39 > > Looks to me like there were 39 fragments or something processed, yet you = can > see above the highlights are empty {}??? > > though all the the other libraries in the highlighter showed no changes. > > which are these... > > org.apache.solr.highlight.BreakIteratorBoundaryScanner > org.apache.solr.highlight.HtmlEncoder > org.apache.solr.highlight.RegexFragmenter > org.apache.solr.highlight.ScoreOrderFragmentsBuilder > org.apache.solr.highlight.SimpleBoundaryScanner > org.apache.solr.highlight.SimpleFragListBuilder > org.apache.solr.highlight.SingleFragListBuilder > org.apache.solr.highlight.WeightedFragListBuilder > > > Scott > > -------- Original Message -------- > Subject: Highlighting, all matches show empty {} > From: Scott Derrick > To: solr-user@lucene.apache.org > Date: 08/12/2015 08:20 AM > >> Tried submitting a filed for hl.fl still empty {} >> >> here are the query terms >> >> "responseHeader": { >> "status": 0, >> "QTime": 8, >> "params": { >> "q": "mary or calvin", >> "hl": "true", >> "hl.simple.post": "", >> "indent": "true", >> "fl": "accession, title, author, date", >> "hl.fl": "*", >> "wt": "json", >> "hl.simple.pre": "", >> "_": "1439388969240" >> } >> >> here is one of the responses, there were 135 >> >> { >> "date": "1886-07-06", >> "author": "Mary Baker Eddy", >> "accession": "L02634", >> "title": [ >> "Mary Baker Eddy to Josephine C. Woodbury, July 6, 1886" >> ] >> }, >> >> here is the highlight section listing the first 10 matches, still empty = {} >> >> "highlighting": { >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./L02634/L02634.html= ": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10720/A10720.html= ": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./L07894/L07894.html= ": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./L09828/L09828.html= ": >> {}, >> >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10636D/A10636D.ht= ml": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./L13943/L13943.html= ": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10594/A10594.html= ": >> {}, >> >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10385B/A10385B.ht= ml": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10879/A10879.html= ": >> {}, >> >> "/home/scott/workspace/mbel-work/tei2html/build/web/./L00003/L00003.html= ": >> {} >> } >> >> >> -------- Original Message -------- >> Subject: Re: Highlighting >> From: Scott Derrick >> To: solr-user@lucene.apache.org >> Date: 08/12/2015 06:39 AM >> >>> I was pretty sure I tried that, though I thought if you don't specify i= t >>> just uses the search terms? >>> >>> If I just search for "calvin" and don't specify a field, what do I >>> assign hl.fl? >>> >>> Scott >>> >>> On 8/11/2015 7:27 PM, Erik Hatcher wrote: >>>> >>>> Scott - doesn=E2=80=99t look you=E2=80=99ve specified hl.fl specifying= which field(s) >>>> to highlight. >>>> >>>> p.s. Erick Erickson surely likes your e-mail domain :) >>>> >>>> >>>> =E2=80=94 >>>> Erik Hatcher, Senior Solutions Architect >>>> http://www.lucidworks.com >>>> >>>> >>>> >>>> >>>>> On Aug 11, 2015, at 9:02 PM, Scott Derrick wrote= : >>>>> >>>>> I guess I really don't get Highlighting in Solr. >>>>> >>>>> We are transitioning from Google Custom Search which generally sucks, >>>>> but does return nicely formatted highlighted fragment. >>>>> >>>>> I turn highlighting on hl=3Dtrue in the query and I get a highlightin= g >>>>> section returned at the bottom of the page, each identified by the >>>>> document file name with a empty {} . It doesn't matter what I search >>>>> for, plain text, a field, I get a list of documents followed by an >>>>> empty brace? >>>>> >>>>> "highlighting": { >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10385B/A10385B= .html": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10089/A10089.h= tml": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./L00003/L00003.h= tml": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10646/A10646.h= tml": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./V03482/V03482.h= tml": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./A10594/A10594.h= tml": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./645A.66.043/645= A.66.043.html": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./352.48.001/352.= 48.001.html": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./144.23.001/144.= 23.001.html": >>>>> >>>>> {}, >>>>> >>>>> "/home/scott/workspace/mbel-work/tei2html/build/web/./L18512/L18512.h= tml": >>>>> >>>>> {} >>>>> } >>>>> >>>>> I haven't made any changes to the default settings >>>>> >>>>> >>>>> >>>>> >>>>> >>>> default=3D"true" >>>>> class=3D"solr.highlight.GapFragmenter"> >>>>> >>>>> 100 >>>>> >>>>> >>>>> >>>>> >>>>> >>>> class=3D"solr.highlight.RegexFragmenter"> >>>>> >>>>> >>>>> 70 >>>>> >>>>> 0.5 >>>>> >>>>> [-\w >>>>> ,/\n\"']{20,200} >>>>> >>>>> >>>>> >>>>> >>>>> >>>> default=3D"true" >>>>> class=3D"solr.highlight.HtmlFormatter"> >>>>> >>>>> ]]> >>>>> ]]> >>>>> >>>>> >>>>> >>>>> >>>>> >>>> class=3D"solr.highlight.HtmlEncoder" /> >>>>> >>>>> >>>>> >>>> class=3D"solr.highlight.SimpleFragListBuilder"= /> >>>>> >>>>> >>>>> >>>> class=3D"solr.highlight.SingleFragListBuilder"= /> >>>>> >>>>> >>>>> >>>> default=3D"true" >>>>> class=3D"solr.highlight.WeightedFragListBuilde= r"/> >>>>> >>>>> >>>>> >>>> default=3D"true" >>>>> >>>>> class=3D"solr.highlight.ScoreOrderFragmentsBuilder"> >>>>> >>>>> >>>>> >>>>> >>>>> >>>> >>>>> class=3D"solr.highlight.ScoreOrderFragmentsBuilder"> >>>>> >>>>> >>>> ,>>>> style=3D"background:lawgreen">, >>>>> ,>>>> style=3D"background:magenta">, >>>>> ,>>>> style=3D"background:coral">, >>>>> ,>>>> style=3D"background:khaki">, >>>>> ,>>>> style=3D"background:deepskyblue">]]> >>>>> ]]> >>>>> >>>>> >>>>> >>>>> >>>> default=3D"true" >>>>> class=3D"solr.highlight.SimpleBoundaryScanner"= > >>>>> >>>>> 10 >>>>> .,!? >>>>> >>>>> >>>>> >>>>> >>>> >>>>> class=3D"solr.highlight.BreakIteratorBoundaryScanner"> >>>>> >>>>> >>>>> WORD >>>>> >>>>> >>>>> en >>>>> US >>>>> >>>>> >>>>> >>>> >>>> >>> >>> >>> --- >>> This email has been checked for viruses by Avast antivirus software. >>> https://www.avast.com/antivirus >>> >>> >> > > -- > One man's "magic" is another man's engineering. "Supernatural" is a null > word.=E2=80=9D > Robert A. Heinlein >