You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk> on 2019/02/25 12:54:36 UTC

MLT and facetting

Hi,

I am trying to combine the mlt functionality with facets, but Solr throws org.apache.solr.common.SolrException: ":"Unable to compute facet ranges, facet context is not set".

What I am trying to do is quite simple, find similar documents using mlt and group these using the facet parameter. When using mlt and facets separately everything works fine, but not when combining the functionality.

[cid:image002.png@01D4CD11.A38E3110]
[cid:image003.png@01D4CD11.A38E3110]

{
  "responseHeader":{
    "status":500,
    "QTime":109},
  "match":{"numFound":1,"start":0,"docs":[
      {
        "Journalnummer":" 00759",
        "id":"6512815"  },
  "response":{"numFound":602234,"start":0,"docs":[
      {
        "Journalnummer":" 00759",
        "id":"6512816",
      {
        "Journalnummer":" 00759",
        "id":"6834653"
      {
        "Journalnummer":" 00739",
        "id":"6202373"
      {
        "Journalnummer":" 00739",
        "id":"6748105"

      {
        "Journalnummer":" 00803",
        "id":"7402155"
  },
  "error":{
    "metadata":[
      "error-class","org.apache.solr.common.SolrException",
      "root-error-class","org.apache.solr.common.SolrException"],
    "msg":"Unable to compute facet ranges, facet context is not set",
    "trace":"org.apache.solr.common.SolrException: Unable to compute facet ranges, facet context is not set\n\tat org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCounts(RangeFacetProcessor.java:66)\n\tat org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetComponent.java:331)\n\tat org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetComponent.java:295)\n\tat org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLikeThisHandler.java:240)\n\tat org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:199)\n\tat org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n\tat org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\tat org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:377)\n\tat org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:323)\n\tat org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1634)\n\tat org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:533)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:146)\n\tat org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:257)\n\tat org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1595)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255)\n\tat org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1317)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:203)\n\tat org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:473)\n\tat org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1564)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:201)\n\tat org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1219)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:144)\n\tat org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:219)\n\tat org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:126)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:335)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\tat org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:260)\n\tat org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)\n\tat org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\tat org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)\n\tat org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:762)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
    "code":500}}


In the above example I would like to facet on Journalnummer, thus grouping several documents based on Journalnummer.

Hope someone can help me, and thanks in advance.

Best regards

Martin

Beskyttelse af dine personlige oplysninger er vigtig for os. Her finder du KMD’s Privatlivspolitik<http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi behandler oplysninger om dig.

Protection of your personal data is important to us. Here you can read KMD’s Privacy Policy<http://www.kmd.net/Privacy-Policy> outlining how we process your personal data.

Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information. Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst informere afsender om fejlen ved at bruge svarfunktionen. Samtidig beder vi dig slette e-mailen i dit system uden at videresende eller kopiere den. Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning er fri for virus og andre fejl, som kan påvirke computeren eller it-systemet, hvori den modtages og læses, åbnes den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som er opstået i forbindelse med at modtage og bruge e-mailen.

Please note that this message may contain confidential information. If you have received this message by mistake, please inform the sender of the mistake by sending a reply, then delete the message from your system without making, distributing or retaining any copies of it. Although we believe that the message and any attachments are free from viruses and other errors that might affect the computer or it-system where it is received and read, the recipient opens the message at his or her own risk. We assume no responsibility for any loss or damage arising from the receipt or use of this message.

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Dave, 

Thanks for your suggestion, I was under the impression that you could do it in one-search approach. But if that’s not possible I will try to divide into two searches. 

Is the best way to do this through Solrj? 

Best regards

Martin


Internal - KMD A/S

-----Original Message-----
From: Dave <ha...@gmail.com> 
Sent: 26. februar 2019 05:39
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Use the mlt to get the queries to use for getting facets in a two search approach

> On Feb 25, 2019, at 10:18 PM, Zheng Lin Edwin Yeo <ed...@gmail.com> wrote:
> 
> Hi Martin,
> 
> I think there are some pictures which are not being sent through in 
> the email.
> 
> Do send your query that you are using, and which version of Solr you 
> are using?
> 
> Regards,
> Edwin
> 
>> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:
>> 
>> Hi,
>> 
>> 
>> 
>> I am trying to combine the mlt functionality with facets, but Solr 
>> throws
>> org.apache.solr.common.SolrException: ":"Unable to compute facet 
>> ranges, facet context is not set".
>> 
>> 
>> 
>> What I am trying to do is quite simple, find similar documents using 
>> mlt and group these using the facet parameter. When using mlt and 
>> facets separately everything works fine, but not when combining the functionality.
>> 
>> 
>> 
>> 
>> 
>> {
>> 
>>  "responseHeader":{
>> 
>>    "status":500,
>> 
>>    "QTime":109},
>> 
>>  "match":{"numFound":1,"start":0,"docs":[
>> 
>>      {
>> 
>>        "Journalnummer":" 00759",
>> 
>>        "id":"6512815"  },
>> 
>>  "response":{"numFound":602234,"start":0,"docs":[
>> 
>>      {
>> 
>>        "Journalnummer":" 00759",
>> 
>>        "id":"6512816",
>> 
>>      {
>> 
>>        "Journalnummer":" 00759",
>> 
>>        "id":"6834653"
>> 
>>      {
>> 
>>        "Journalnummer":" 00739",
>> 
>>        "id":"6202373"
>> 
>>      {
>> 
>>        "Journalnummer":" 00739",
>> 
>>        "id":"6748105"
>> 
>> 
>> 
>>      {
>> 
>>        "Journalnummer":" 00803",
>> 
>>        "id":"7402155"
>> 
>>  },
>> 
>>  "error":{
>> 
>>    "metadata":[
>> 
>>      "error-class","org.apache.solr.common.SolrException",
>> 
>>      "root-error-class","org.apache.solr.common.SolrException"],
>> 
>>    "msg":"Unable to compute facet ranges, facet context is not set",
>> 
>>    "trace":"org.apache.solr.common.SolrException: Unable to compute 
>> facet ranges, facet context is not set\n\tat 
>> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCo
>> unts(RangeFacetProcessor.java:66)\n\tat
>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(Facet
>> Component.java:331)\n\tat 
>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(Facet
>> Component.java:295)\n\tat 
>> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLik
>> eThisHandler.java:240)\n\tat 
>> org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandl
>> erBase.java:199)\n\tat 
>> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
>> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n
>> \tat 
>> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\ta
>> t 
>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilte
>> r.java:377)\n\tat 
>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilte
>> r.java:323)\n\tat 
>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet
>> Handler.java:1634)\n\tat 
>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java
>> :533)\n\tat 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.j
>> ava:146)\n\tat 
>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.jav
>> a:548)\n\tat 
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper
>> .java:132)\n\tat 
>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandl
>> er.java:257)\n\tat 
>> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandl
>> er.java:1595)\n\tat 
>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandl
>> er.java:255)\n\tat 
>> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandl
>> er.java:1317)\n\tat 
>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandle
>> r.java:203)\n\tat 
>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:
>> 473)\n\tat 
>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandle
>> r.java:1564)\n\tat 
>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandle
>> r.java:201)\n\tat 
>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandle
>> r.java:1219)\n\tat 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.j
>> ava:144)\n\tat 
>> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(Cont
>> extHandlerCollection.java:219)\n\tat
>> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerColl
>> ection.java:126)\n\tat 
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper
>> .java:132)\n\tat 
>> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandle
>> r.java:335)\n\tat 
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper
>> .java:132)\n\tat 
>> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\t
>> at 
>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.jav
>> a:260)\n\tat 
>> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstra
>> ctConnection.java:281)\n\tat 
>> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\t
>> at 
>> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\
>> n\tat 
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhat
>> YouKill.java:333)\n\tat 
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWh
>> atYouKill.java:310)\n\tat 
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatW
>> hatYouKill.java:168)\n\tat 
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouK
>> ill.java:126)\n\tat 
>> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.r
>> un(ReservedThreadExecutor.java:366)\n\tat
>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPoo
>> l.java:762)\n\tat 
>> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool
>> .java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>> 
>>    "code":500}}
>> 
>> 
>> 
>> 
>> 
>> In the above example I would like to facet on Journalnummer, thus 
>> grouping several documents based on Journalnummer.
>> 
>> 
>> 
>> Hope someone can help me, and thanks in advance.
>> 
>> 
>> 
>> Best regards
>> 
>> 
>> 
>> Martin
>> 
>> Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
>> finder du KMD’s Privatlivspolitik 
>> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi behandler oplysninger om dig.
>> 
>> Protection of your personal data is important to us. Here you can 
>> read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy> 
>> outlining how we process your personal data.
>> 
>> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
>> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst 
>> informere afsender om fejlen ved at bruge svarfunktionen. Samtidig 
>> beder vi dig slette e-mailen i dit system uden at videresende eller kopiere den.
>> Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning 
>> er fri for virus og andre fejl, som kan påvirke computeren eller 
>> it-systemet, hvori den modtages og læses, åbnes den på modtagerens 
>> eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som er 
>> opstået i forbindelse med at modtage og bruge e-mailen.
>> 
>> Please note that this message may contain confidential information. 
>> If you have received this message by mistake, please inform the 
>> sender of the mistake by sending a reply, then delete the message 
>> from your system without making, distributing or retaining any copies 
>> of it. Although we believe that the message and any attachments are 
>> free from viruses and other errors that might affect the computer or 
>> it-system where it is received and read, the recipient opens the message at his or her own risk.
>> We assume no responsibility for any loss or damage arising from the 
>> receipt or use of this message.
>> 

Re: MLT and facetting

Posted by Dave <ha...@gmail.com>.
Use the mlt to get the queries to use for getting facets in a two search approach

> On Feb 25, 2019, at 10:18 PM, Zheng Lin Edwin Yeo <ed...@gmail.com> wrote:
> 
> Hi Martin,
> 
> I think there are some pictures which are not being sent through in the
> email.
> 
> Do send your query that you are using, and which version of Solr you are
> using?
> 
> Regards,
> Edwin
> 
>> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:
>> 
>> Hi,
>> 
>> 
>> 
>> I am trying to combine the mlt functionality with facets, but Solr throws
>> org.apache.solr.common.SolrException: ":"Unable to compute facet ranges,
>> facet context is not set".
>> 
>> 
>> 
>> What I am trying to do is quite simple, find similar documents using mlt
>> and group these using the facet parameter. When using mlt and facets
>> separately everything works fine, but not when combining the functionality.
>> 
>> 
>> 
>> 
>> 
>> {
>> 
>>  "responseHeader":{
>> 
>>    "status":500,
>> 
>>    "QTime":109},
>> 
>>  "match":{"numFound":1,"start":0,"docs":[
>> 
>>      {
>> 
>>        "Journalnummer":" 00759",
>> 
>>        "id":"6512815"  },
>> 
>>  "response":{"numFound":602234,"start":0,"docs":[
>> 
>>      {
>> 
>>        "Journalnummer":" 00759",
>> 
>>        "id":"6512816",
>> 
>>      {
>> 
>>        "Journalnummer":" 00759",
>> 
>>        "id":"6834653"
>> 
>>      {
>> 
>>        "Journalnummer":" 00739",
>> 
>>        "id":"6202373"
>> 
>>      {
>> 
>>        "Journalnummer":" 00739",
>> 
>>        "id":"6748105"
>> 
>> 
>> 
>>      {
>> 
>>        "Journalnummer":" 00803",
>> 
>>        "id":"7402155"
>> 
>>  },
>> 
>>  "error":{
>> 
>>    "metadata":[
>> 
>>      "error-class","org.apache.solr.common.SolrException",
>> 
>>      "root-error-class","org.apache.solr.common.SolrException"],
>> 
>>    "msg":"Unable to compute facet ranges, facet context is not set",
>> 
>>    "trace":"org.apache.solr.common.SolrException: Unable to compute facet
>> ranges, facet context is not set\n\tat
>> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCounts(RangeFacetProcessor.java:66)\n\tat
>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetComponent.java:331)\n\tat
>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetComponent.java:295)\n\tat
>> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLikeThisHandler.java:240)\n\tat
>> org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:199)\n\tat
>> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
>> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n\tat
>> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\tat
>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:377)\n\tat
>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:323)\n\tat
>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1634)\n\tat
>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:533)\n\tat
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:146)\n\tat
>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548)\n\tat
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat
>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:257)\n\tat
>> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1595)\n\tat
>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255)\n\tat
>> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1317)\n\tat
>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:203)\n\tat
>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:473)\n\tat
>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1564)\n\tat
>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:201)\n\tat
>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1219)\n\tat
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:144)\n\tat
>> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:219)\n\tat
>> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:126)\n\tat
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat
>> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:335)\n\tat
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat
>> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\tat
>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:260)\n\tat
>> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)\n\tat
>> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\tat
>> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\n\tat
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)\n\tat
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)\n\tat
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)\n\tat
>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)\n\tat
>> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)\n\tat
>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:762)\n\tat
>> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:680)\n\tat
>> java.lang.Thread.run(Thread.java:748)\n",
>> 
>>    "code":500}}
>> 
>> 
>> 
>> 
>> 
>> In the above example I would like to facet on Journalnummer, thus grouping
>> several documents based on Journalnummer.
>> 
>> 
>> 
>> Hope someone can help me, and thanks in advance.
>> 
>> 
>> 
>> Best regards
>> 
>> 
>> 
>> Martin
>> 
>> Beskyttelse af dine personlige oplysninger er vigtig for os. Her finder du KMD’s
>> Privatlivspolitik <http://www.kmd.dk/Privatlivspolitik>, der fortæller,
>> hvordan vi behandler oplysninger om dig.
>> 
>> Protection of your personal data is important to us. Here you can read KMD’s
>> Privacy Policy <http://www.kmd.net/Privacy-Policy> outlining how we
>> process your personal data.
>> 
>> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
>> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst
>> informere afsender om fejlen ved at bruge svarfunktionen. Samtidig beder vi
>> dig slette e-mailen i dit system uden at videresende eller kopiere den.
>> Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning er fri
>> for virus og andre fejl, som kan påvirke computeren eller it-systemet,
>> hvori den modtages og læses, åbnes den på modtagerens eget ansvar. Vi
>> påtager os ikke noget ansvar for tab og skade, som er opstået i forbindelse
>> med at modtage og bruge e-mailen.
>> 
>> Please note that this message may contain confidential information. If you
>> have received this message by mistake, please inform the sender of the
>> mistake by sending a reply, then delete the message from your system
>> without making, distributing or retaining any copies of it. Although we
>> believe that the message and any attachments are free from viruses and
>> other errors that might affect the computer or it-system where it is
>> received and read, the recipient opens the message at his or her own risk.
>> We assume no responsibility for any loss or damage arising from the receipt
>> or use of this message.
>> 

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Walter, 

Thanks for your answer, it makes sense. 

Best regards
Martin


Internal - KMD A/S

-----Original Message-----
From: Walter Underwood <wu...@wunderwood.org> 
Sent: 1. marts 2019 03:30
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

The last time I looked, the MLT was a search handler but not a search component. It wasn’t able to be combined with other features. The handler is based on very old code, like 1.3.

wunder
Walter Underwood
wunder@wunderwood.org
http://observer.wunderwood.org/  (my blog)

> On Feb 28, 2019, at 5:47 PM, Zheng Lin Edwin Yeo <ed...@gmail.com> wrote:
> 
> Hi Martin,
> 
> I have no idea on this, as the case has not been active for almost 2 years.
> Maybe I can try to follow up.
> 
> Faceting by default will show the list according to the number of 
> occurrences. But I'm not sure how it will affect the MLT score or how 
> it will be output when combine together, as it is not working 
> currently and there is no way to test.
> 
> Regards,
> Edwin
> 
> On Thu, 28 Feb 2019 at 14:51, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:
> 
>> Hi Edwin,
>> 
>> Ok that is nice to know. Do you know when this bug will get fixed?
>> 
>> By ordering I mean that MLT score the documents according to its 
>> similarity function (believe it is cosine similarity), and I don’t 
>> know how faceting will affect this score? Or ignore it all together?
>> 
>> Best regards
>> 
>> Martin
>> 
>> 
>> Internal - KMD A/S
>> 
>> -----Original Message-----
>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>> Sent: 28. februar 2019 06:19
>> To: solr-user@lucene.apache.org
>> Subject: Re: MLT and facetting
>> 
>> Hi Martin,
>> 
>> According to the JIRA, it says it is a bug, as it was working 
>> previously in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.
>> 
>> For the ordering of the documents, do you mean to sort them according 
>> to the criteria that you want?
>> 
>> Regards,
>> Edwin
>> 
>> On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>> wrote:
>> 
>>> Hi Edwin,
>>> 
>>> Thanks for your response. Are you sure it is a bug? Or is it not 
>>> meant to work together?
>>> After doing some thinking I do see a problem faceting a MLT-result.
>>> MLT-results have a clear ordering of the documents which will be 
>>> hard to maintain with facets. How will faceting MLT-results deal 
>>> with the ordering of the documents? Will the ordering just be ignored?
>>> 
>>> Best regards
>>> 
>>> Martin
>>> 
>>> 
>>> 
>>> Internal - KMD A/S
>>> 
>>> -----Original Message-----
>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>> Sent: 27. februar 2019 03:38
>>> To: solr-user@lucene.apache.org
>>> Subject: Re: MLT and facetting
>>> 
>>> Hi Martin,
>>> 
>>> I also get the same problem in Solr 7.7 if I turn on faceting in 
>>> /mlt requestHandler.
>>> 
>>> Found this issue in the JIRA:
>>> https://issues.apache.org/jira/browse/SOLR-7883
>>> Seems like it is a bug in Solr and it has not been resolved yet.
>>> 
>>> Regards,
>>> Edwin
>>> 
>>> On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>>> wrote:
>>> 
>>>> Hi Edwin,
>>>> 
>>>> Here it is:
>>>> 
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
>>>> 
>>>> 
>>>> -<lst name="defaults">
>>>> 
>>>> <str name="mlt.fl">text</str>
>>>> 
>>>> <str name="mlt.mintf">1</str>
>>>> 
>>>> <str name="mlt.mindf">1</str>
>>>> 
>>>> <str name="mlt.interestingTerms">true</str>
>>>> 
>>>> </lst>
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> Internal - KMD A/S
>>>> 
>>>> -----Original Message-----
>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>> Sent: 26. februar 2019 08:24
>>>> To: solr-user@lucene.apache.org
>>>> Subject: Re: MLT and facetting
>>>> 
>>>> Hi Martin,
>>>> 
>>>> What is your setting in your /mlt requestHandler in solrconfig.xml?
>>>> 
>>>> Regards,
>>>> Edwin
>>>> 
>>>> On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) 
>>>> <MH...@kmd.dk>
>>>> wrote:
>>>> 
>>>>> Hi Edwin,
>>>>> 
>>>>> Thanks for your response.
>>>>> 
>>>>> Yes you are right. It was simply the search parameters from Solr.
>>>>> 
>>>>> The query looks like this:
>>>>> 
>>>>> http://
>>>>> .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,
>>>>> Jo
>>>>> ur
>>>>> nalnummer&q=id:*6512815*
>>>>> 
>>>>> best regards,
>>>>> 
>>>>> Martin
>>>>> 
>>>>> 
>>>>> Internal - KMD A/S
>>>>> 
>>>>> -----Original Message-----
>>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>>> Sent: 26. februar 2019 03:54
>>>>> To: solr-user@lucene.apache.org
>>>>> Subject: Re: MLT and facetting
>>>>> 
>>>>> Hi Martin,
>>>>> 
>>>>> I think there are some pictures which are not being sent through 
>>>>> in the email.
>>>>> 
>>>>> Do send your query that you are using, and which version of Solr 
>>>>> you are using?
>>>>> 
>>>>> Regards,
>>>>> Edwin
>>>>> 
>>>>> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) 
>>>>> <MH...@kmd.dk>
>>>>> wrote:
>>>>> 
>>>>>> Hi,
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> I am trying to combine the mlt functionality with facets, but 
>>>>>> Solr throws
>>>>>> org.apache.solr.common.SolrException: ":"Unable to compute facet 
>>>>>> ranges, facet context is not set".
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> What I am trying to do is quite simple, find similar documents 
>>>>>> using mlt and group these using the facet parameter. When using 
>>>>>> mlt and facets separately everything works fine, but not when 
>>>>>> combining the
>>>>> functionality.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> {
>>>>>> 
>>>>>>  "responseHeader":{
>>>>>> 
>>>>>>    "status":500,
>>>>>> 
>>>>>>    "QTime":109},
>>>>>> 
>>>>>>  "match":{"numFound":1,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512815"  },
>>>>>> 
>>>>>>  "response":{"numFound":602234,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512816",
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6834653"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6202373"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6748105"
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00803",
>>>>>> 
>>>>>>        "id":"7402155"
>>>>>> 
>>>>>>  },
>>>>>> 
>>>>>>  "error":{
>>>>>> 
>>>>>>    "metadata":[
>>>>>> 
>>>>>>      "error-class","org.apache.solr.common.SolrException",
>>>>>> 
>>>>>> 
>>>>>> "root-error-class","org.apache.solr.common.SolrException"],
>>>>>> 
>>>>>>    "msg":"Unable to compute facet ranges, facet context is not 
>>>>>> set",
>>>>>> 
>>>>>>    "trace":"org.apache.solr.common.SolrException: Unable to 
>>>>>> compute facet ranges, facet context is not set\n\tat 
>>>>>> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRa
>>>>>> ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:331)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:295)\n\tat
>>>>>> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(Mo
>>>>>> re
>>>>>> Li
>>>>>> ke
>>>>>> ThisHandler.java:240)\n\tat
>>>>>> org.apache.solr.handler.RequestHandlerBase.handleRequest(Request
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> rBase.java:199)\n\tat
>>>>>> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:7
>>>>>> 09
>>>>>> )\
>>>>>> n\
>>>>>> tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)
>>>>>> \n
>>>>>> \t
>>>>>> at
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:377)\n\tat
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:323)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Se
>>>>>> rv
>>>>>> le
>>>>>> tH
>>>>>> andler.java:1634)\n\tat
>>>>>> 
>>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
>>>>>> 533)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:146)\n\tat
>>>>>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
>>>>>> ja
>>>>>> va
>>>>>> :548)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:257)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doHandle(Session
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1595)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:255)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doHandle(Context
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1317)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:203)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
>>>>>> ja
>>>>>> va
>>>>>> :4
>>>>>> 73)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1564)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:201)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1219)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:144)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle
>>>>>> (C
>>>>>> on
>>>>>> te
>>>>>> xtHandlerCollection.java:219)\n\tat
>>>>>> org.eclipse.jetty.server.handler.HandlerCollection.handle(Handle
>>>>>> rC
>>>>>> ol
>>>>>> le
>>>>>> ction.java:126)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:335)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
>>>>>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
>>>>>> ja
>>>>>> va
>>>>>> :260)\n\tat
>>>>>> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(A
>>>>>> bs
>>>>>> tr
>>>>>> ac
>>>>>> tConnection.java:281)\n\tat
>>>>>> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
>>>>>> 11
>>>>>> 8)
>>>>>> \n
>>>>>> \tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(Ea
>>>>>> tW
>>>>>> ha
>>>>>> tY
>>>>>> ouKill.java:333)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(
>>>>>> Ea
>>>>>> tW
>>>>>> ha
>>>>>> tYouKill.java:310)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce
>>>>>> (E
>>>>>> at
>>>>>> Wh
>>>>>> atYouKill.java:168)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWha
>>>>>> tY
>>>>>> ou
>>>>>> Ki
>>>>>> ll.java:126)\n\tat
>>>>>> 
>> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
>>>>>> ru n(ReservedThreadExecutor.java:366)\n\tat
>>>>>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThre
>>>>>> ad
>>>>>> Po
>>>>>> ol
>>>>>> .java:762)\n\tat
>>>>>> 
>>> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
>>>>>> java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>>>>>> 
>>>>>>    "code":500}}
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> In the above example I would like to facet on Journalnummer, thus 
>>>>>> grouping several documents based on Journalnummer.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Hope someone can help me, and thanks in advance.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Best regards
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Martin
>>>>>> 
>>>>>> Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
>>>>>> finder du KMD’s Privatlivspolitik 
>>>>>> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
>>>>> behandler oplysninger om dig.
>>>>>> 
>>>>>> Protection of your personal data is important to us. Here you can 
>>>>>> read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy>
>>>>>> outlining how we process your personal data.
>>>>>> 
>>>>>> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
>>>> information.
>>>>>> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig 
>>>>>> venligst informere afsender om fejlen ved at bruge svarfunktionen.
>>>>>> Samtidig beder vi dig slette e-mailen i dit system uden at 
>>>>>> videresende eller
>>>>> kopiere den.
>>>>>> Selvom e-mailen og ethvert vedhæftet bilag efter vores 
>>>>>> overbevisning er fri for virus og andre fejl, som kan påvirke 
>>>>>> computeren eller it-systemet, hvori den modtages og læses, åbnes 
>>>>>> den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar 
>>>>>> for tab og skade, som er opstået i forbindelse med at modtage og
>>> bruge e-mailen.
>>>>>> 
>>>>>> Please note that this message may contain confidential information.
>>>>>> If you have received this message by mistake, please inform the 
>>>>>> sender of the mistake by sending a reply, then delete the message 
>>>>>> from your system without making, distributing or retaining any 
>>>>>> copies
>>>> of it.
>>>>>> Although we believe that the message and any attachments are free 
>>>>>> from viruses and other errors that might affect the computer or 
>>>>>> it-system where it is received and read, the recipient opens the 
>>>>>> message at his or
>>>>> her own risk.
>>>>>> We assume no responsibility for any loss or damage arising from 
>>>>>> the receipt or use of this message.
>>>>>> 
>>>> 
>>> 
>> 

Re: MLT and facetting

Posted by Walter Underwood <wu...@wunderwood.org>.
The last time I looked, the MLT was a search handler but not a search component. It wasn’t able to be combined with other features. The handler is based on very old code, like 1.3.

wunder
Walter Underwood
wunder@wunderwood.org
http://observer.wunderwood.org/  (my blog)

> On Feb 28, 2019, at 5:47 PM, Zheng Lin Edwin Yeo <ed...@gmail.com> wrote:
> 
> Hi Martin,
> 
> I have no idea on this, as the case has not been active for almost 2 years.
> Maybe I can try to follow up.
> 
> Faceting by default will show the list according to the number of
> occurrences. But I'm not sure how it will affect the MLT score or how it
> will be output when combine together, as it is not working currently and
> there is no way to test.
> 
> Regards,
> Edwin
> 
> On Thu, 28 Feb 2019 at 14:51, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:
> 
>> Hi Edwin,
>> 
>> Ok that is nice to know. Do you know when this bug will get fixed?
>> 
>> By ordering I mean that MLT score the documents according to its
>> similarity function (believe it is cosine similarity), and I don’t know how
>> faceting will affect this score? Or ignore it all together?
>> 
>> Best regards
>> 
>> Martin
>> 
>> 
>> Internal - KMD A/S
>> 
>> -----Original Message-----
>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>> Sent: 28. februar 2019 06:19
>> To: solr-user@lucene.apache.org
>> Subject: Re: MLT and facetting
>> 
>> Hi Martin,
>> 
>> According to the JIRA, it says it is a bug, as it was working previously
>> in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.
>> 
>> For the ordering of the documents, do you mean to sort them according to
>> the criteria that you want?
>> 
>> Regards,
>> Edwin
>> 
>> On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>> wrote:
>> 
>>> Hi Edwin,
>>> 
>>> Thanks for your response. Are you sure it is a bug? Or is it not meant
>>> to work together?
>>> After doing some thinking I do see a problem faceting a MLT-result.
>>> MLT-results have a clear ordering of the documents which will be hard
>>> to maintain with facets. How will faceting MLT-results deal with the
>>> ordering of the documents? Will the ordering just be ignored?
>>> 
>>> Best regards
>>> 
>>> Martin
>>> 
>>> 
>>> 
>>> Internal - KMD A/S
>>> 
>>> -----Original Message-----
>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>> Sent: 27. februar 2019 03:38
>>> To: solr-user@lucene.apache.org
>>> Subject: Re: MLT and facetting
>>> 
>>> Hi Martin,
>>> 
>>> I also get the same problem in Solr 7.7 if I turn on faceting in /mlt
>>> requestHandler.
>>> 
>>> Found this issue in the JIRA:
>>> https://issues.apache.org/jira/browse/SOLR-7883
>>> Seems like it is a bug in Solr and it has not been resolved yet.
>>> 
>>> Regards,
>>> Edwin
>>> 
>>> On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>>> wrote:
>>> 
>>>> Hi Edwin,
>>>> 
>>>> Here it is:
>>>> 
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
>>>> 
>>>> 
>>>> -<lst name="defaults">
>>>> 
>>>> <str name="mlt.fl">text</str>
>>>> 
>>>> <str name="mlt.mintf">1</str>
>>>> 
>>>> <str name="mlt.mindf">1</str>
>>>> 
>>>> <str name="mlt.interestingTerms">true</str>
>>>> 
>>>> </lst>
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> Internal - KMD A/S
>>>> 
>>>> -----Original Message-----
>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>> Sent: 26. februar 2019 08:24
>>>> To: solr-user@lucene.apache.org
>>>> Subject: Re: MLT and facetting
>>>> 
>>>> Hi Martin,
>>>> 
>>>> What is your setting in your /mlt requestHandler in solrconfig.xml?
>>>> 
>>>> Regards,
>>>> Edwin
>>>> 
>>>> On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>>>> wrote:
>>>> 
>>>>> Hi Edwin,
>>>>> 
>>>>> Thanks for your response.
>>>>> 
>>>>> Yes you are right. It was simply the search parameters from Solr.
>>>>> 
>>>>> The query looks like this:
>>>>> 
>>>>> http://
>>>>> .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,
>>>>> Jo
>>>>> ur
>>>>> nalnummer&q=id:*6512815*
>>>>> 
>>>>> best regards,
>>>>> 
>>>>> Martin
>>>>> 
>>>>> 
>>>>> Internal - KMD A/S
>>>>> 
>>>>> -----Original Message-----
>>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>>> Sent: 26. februar 2019 03:54
>>>>> To: solr-user@lucene.apache.org
>>>>> Subject: Re: MLT and facetting
>>>>> 
>>>>> Hi Martin,
>>>>> 
>>>>> I think there are some pictures which are not being sent through
>>>>> in the email.
>>>>> 
>>>>> Do send your query that you are using, and which version of Solr
>>>>> you are using?
>>>>> 
>>>>> Regards,
>>>>> Edwin
>>>>> 
>>>>> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ)
>>>>> <MH...@kmd.dk>
>>>>> wrote:
>>>>> 
>>>>>> Hi,
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> I am trying to combine the mlt functionality with facets, but
>>>>>> Solr throws
>>>>>> org.apache.solr.common.SolrException: ":"Unable to compute facet
>>>>>> ranges, facet context is not set".
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> What I am trying to do is quite simple, find similar documents
>>>>>> using mlt and group these using the facet parameter. When using
>>>>>> mlt and facets separately everything works fine, but not when
>>>>>> combining the
>>>>> functionality.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> {
>>>>>> 
>>>>>>  "responseHeader":{
>>>>>> 
>>>>>>    "status":500,
>>>>>> 
>>>>>>    "QTime":109},
>>>>>> 
>>>>>>  "match":{"numFound":1,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512815"  },
>>>>>> 
>>>>>>  "response":{"numFound":602234,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512816",
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6834653"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6202373"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6748105"
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00803",
>>>>>> 
>>>>>>        "id":"7402155"
>>>>>> 
>>>>>>  },
>>>>>> 
>>>>>>  "error":{
>>>>>> 
>>>>>>    "metadata":[
>>>>>> 
>>>>>>      "error-class","org.apache.solr.common.SolrException",
>>>>>> 
>>>>>> 
>>>>>> "root-error-class","org.apache.solr.common.SolrException"],
>>>>>> 
>>>>>>    "msg":"Unable to compute facet ranges, facet context is not
>>>>>> set",
>>>>>> 
>>>>>>    "trace":"org.apache.solr.common.SolrException: Unable to
>>>>>> compute facet ranges, facet context is not set\n\tat
>>>>>> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRa
>>>>>> ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:331)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:295)\n\tat
>>>>>> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(Mo
>>>>>> re
>>>>>> Li
>>>>>> ke
>>>>>> ThisHandler.java:240)\n\tat
>>>>>> org.apache.solr.handler.RequestHandlerBase.handleRequest(Request
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> rBase.java:199)\n\tat
>>>>>> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:7
>>>>>> 09
>>>>>> )\
>>>>>> n\
>>>>>> tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)
>>>>>> \n
>>>>>> \t
>>>>>> at
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:377)\n\tat
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:323)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Se
>>>>>> rv
>>>>>> le
>>>>>> tH
>>>>>> andler.java:1634)\n\tat
>>>>>> 
>>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
>>>>>> 533)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:146)\n\tat
>>>>>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
>>>>>> ja
>>>>>> va
>>>>>> :548)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:257)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doHandle(Session
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1595)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:255)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doHandle(Context
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1317)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:203)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
>>>>>> ja
>>>>>> va
>>>>>> :4
>>>>>> 73)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1564)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:201)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1219)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:144)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle
>>>>>> (C
>>>>>> on
>>>>>> te
>>>>>> xtHandlerCollection.java:219)\n\tat
>>>>>> org.eclipse.jetty.server.handler.HandlerCollection.handle(Handle
>>>>>> rC
>>>>>> ol
>>>>>> le
>>>>>> ction.java:126)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:335)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
>>>>>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
>>>>>> ja
>>>>>> va
>>>>>> :260)\n\tat
>>>>>> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(A
>>>>>> bs
>>>>>> tr
>>>>>> ac
>>>>>> tConnection.java:281)\n\tat
>>>>>> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
>>>>>> 11
>>>>>> 8)
>>>>>> \n
>>>>>> \tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(Ea
>>>>>> tW
>>>>>> ha
>>>>>> tY
>>>>>> ouKill.java:333)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(
>>>>>> Ea
>>>>>> tW
>>>>>> ha
>>>>>> tYouKill.java:310)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce
>>>>>> (E
>>>>>> at
>>>>>> Wh
>>>>>> atYouKill.java:168)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWha
>>>>>> tY
>>>>>> ou
>>>>>> Ki
>>>>>> ll.java:126)\n\tat
>>>>>> 
>> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
>>>>>> ru n(ReservedThreadExecutor.java:366)\n\tat
>>>>>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThre
>>>>>> ad
>>>>>> Po
>>>>>> ol
>>>>>> .java:762)\n\tat
>>>>>> 
>>> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
>>>>>> java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>>>>>> 
>>>>>>    "code":500}}
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> In the above example I would like to facet on Journalnummer,
>>>>>> thus grouping several documents based on Journalnummer.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Hope someone can help me, and thanks in advance.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Best regards
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Martin
>>>>>> 
>>>>>> Beskyttelse af dine personlige oplysninger er vigtig for os. Her
>>>>>> finder du KMD’s Privatlivspolitik
>>>>>> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
>>>>> behandler oplysninger om dig.
>>>>>> 
>>>>>> Protection of your personal data is important to us. Here you
>>>>>> can read KMD’s Privacy Policy
>>>>>> <http://www.kmd.net/Privacy-Policy>
>>>>>> outlining how we process your personal data.
>>>>>> 
>>>>>> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
>>>> information.
>>>>>> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig
>>>>>> venligst informere afsender om fejlen ved at bruge svarfunktionen.
>>>>>> Samtidig beder vi dig slette e-mailen i dit system uden at
>>>>>> videresende eller
>>>>> kopiere den.
>>>>>> Selvom e-mailen og ethvert vedhæftet bilag efter vores
>>>>>> overbevisning er fri for virus og andre fejl, som kan påvirke
>>>>>> computeren eller it-systemet, hvori den modtages og læses, åbnes
>>>>>> den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar
>>>>>> for tab og skade, som er opstået i forbindelse med at modtage og
>>> bruge e-mailen.
>>>>>> 
>>>>>> Please note that this message may contain confidential information.
>>>>>> If you have received this message by mistake, please inform the
>>>>>> sender of the mistake by sending a reply, then delete the
>>>>>> message from your system without making, distributing or
>>>>>> retaining any copies
>>>> of it.
>>>>>> Although we believe that the message and any attachments are
>>>>>> free from viruses and other errors that might affect the
>>>>>> computer or it-system where it is received and read, the
>>>>>> recipient opens the message at his or
>>>>> her own risk.
>>>>>> We assume no responsibility for any loss or damage arising from
>>>>>> the receipt or use of this message.
>>>>>> 
>>>> 
>>> 
>> 


RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Edwin, 

Thanks for your time, much appreciated. 

Best regards 
Martin


Internal - KMD A/S

-----Original Message-----
From: Zheng Lin Edwin Yeo <ed...@gmail.com> 
Sent: 1. marts 2019 02:48
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Hi Martin,

I have no idea on this, as the case has not been active for almost 2 years.
Maybe I can try to follow up.

Faceting by default will show the list according to the number of occurrences. But I'm not sure how it will affect the MLT score or how it will be output when combine together, as it is not working currently and there is no way to test.

Regards,
Edwin

On Thu, 28 Feb 2019 at 14:51, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Ok that is nice to know. Do you know when this bug will get fixed?
>
> By ordering I mean that MLT score the documents according to its 
> similarity function (believe it is cosine similarity), and I don’t 
> know how faceting will affect this score? Or ignore it all together?
>
> Best regards
>
> Martin
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 28. februar 2019 06:19
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> According to the JIRA, it says it is a bug, as it was working 
> previously in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.
>
> For the ordering of the documents, do you mean to sort them according 
> to the criteria that you want?
>
> Regards,
> Edwin
>
> On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi Edwin,
> >
> > Thanks for your response. Are you sure it is a bug? Or is it not 
> > meant to work together?
> > After doing some thinking I do see a problem faceting a MLT-result.
> > MLT-results have a clear ordering of the documents which will be 
> > hard to maintain with facets. How will faceting MLT-results deal 
> > with the ordering of the documents? Will the ordering just be ignored?
> >
> > Best regards
> >
> > Martin
> >
> >
> >
> > Internal - KMD A/S
> >
> > -----Original Message-----
> > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > Sent: 27. februar 2019 03:38
> > To: solr-user@lucene.apache.org
> > Subject: Re: MLT and facetting
> >
> > Hi Martin,
> >
> > I also get the same problem in Solr 7.7 if I turn on faceting in 
> > /mlt requestHandler.
> >
> > Found this issue in the JIRA:
> > https://issues.apache.org/jira/browse/SOLR-7883
> > Seems like it is a bug in Solr and it has not been resolved yet.
> >
> > Regards,
> > Edwin
> >
> > On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > wrote:
> >
> > > Hi Edwin,
> > >
> > > Here it is:
> > >
> > >
> > > </requestHandler>
> > >
> > >
> > > -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
> > >
> > >
> > > -<lst name="defaults">
> > >
> > > <str name="mlt.fl">text</str>
> > >
> > > <str name="mlt.mintf">1</str>
> > >
> > > <str name="mlt.mindf">1</str>
> > >
> > > <str name="mlt.interestingTerms">true</str>
> > >
> > > </lst>
> > >
> > > </requestHandler>
> > >
> > >
> > > Internal - KMD A/S
> > >
> > > -----Original Message-----
> > > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > > Sent: 26. februar 2019 08:24
> > > To: solr-user@lucene.apache.org
> > > Subject: Re: MLT and facetting
> > >
> > > Hi Martin,
> > >
> > > What is your setting in your /mlt requestHandler in solrconfig.xml?
> > >
> > > Regards,
> > > Edwin
> > >
> > > On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) 
> > > <MH...@kmd.dk>
> > > wrote:
> > >
> > > > Hi Edwin,
> > > >
> > > > Thanks for your response.
> > > >
> > > > Yes you are right. It was simply the search parameters from Solr.
> > > >
> > > > The query looks like this:
> > > >
> > > > http://
> > > > .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=i
> > > > d,
> > > > Jo
> > > > ur
> > > > nalnummer&q=id:*6512815*
> > > >
> > > > best regards,
> > > >
> > > > Martin
> > > >
> > > >
> > > > Internal - KMD A/S
> > > >
> > > > -----Original Message-----
> > > > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > > > Sent: 26. februar 2019 03:54
> > > > To: solr-user@lucene.apache.org
> > > > Subject: Re: MLT and facetting
> > > >
> > > > Hi Martin,
> > > >
> > > > I think there are some pictures which are not being sent through 
> > > > in the email.
> > > >
> > > > Do send your query that you are using, and which version of Solr 
> > > > you are using?
> > > >
> > > > Regards,
> > > > Edwin
> > > >
> > > > On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) 
> > > > <MH...@kmd.dk>
> > > > wrote:
> > > >
> > > > > Hi,
> > > > >
> > > > >
> > > > >
> > > > > I am trying to combine the mlt functionality with facets, but 
> > > > > Solr throws
> > > > > org.apache.solr.common.SolrException: ":"Unable to compute 
> > > > > facet ranges, facet context is not set".
> > > > >
> > > > >
> > > > >
> > > > > What I am trying to do is quite simple, find similar documents 
> > > > > using mlt and group these using the facet parameter. When 
> > > > > using mlt and facets separately everything works fine, but not 
> > > > > when combining the
> > > > functionality.
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > {
> > > > >
> > > > >   "responseHeader":{
> > > > >
> > > > >     "status":500,
> > > > >
> > > > >     "QTime":109},
> > > > >
> > > > >   "match":{"numFound":1,"start":0,"docs":[
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00759",
> > > > >
> > > > >         "id":"6512815"  },
> > > > >
> > > > >   "response":{"numFound":602234,"start":0,"docs":[
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00759",
> > > > >
> > > > >         "id":"6512816",
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00759",
> > > > >
> > > > >         "id":"6834653"
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00739",
> > > > >
> > > > >         "id":"6202373"
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00739",
> > > > >
> > > > >         "id":"6748105"
> > > > >
> > > > >
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00803",
> > > > >
> > > > >         "id":"7402155"
> > > > >
> > > > >   },
> > > > >
> > > > >   "error":{
> > > > >
> > > > >     "metadata":[
> > > > >
> > > > >       "error-class","org.apache.solr.common.SolrException",
> > > > >
> > > > >
> > > > > "root-error-class","org.apache.solr.common.SolrException"],
> > > > >
> > > > >     "msg":"Unable to compute facet ranges, facet context is 
> > > > > not set",
> > > > >
> > > > >     "trace":"org.apache.solr.common.SolrException: Unable to 
> > > > > compute facet ranges, facet context is not set\n\tat 
> > > > > org.apache.solr.handler.component.RangeFacetProcessor.getFacet
> > > > > Ra ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
> > > > > org.apache.solr.handler.component.FacetComponent.getFacetCount
> > > > > s(
> > > > > Fa
> > > > > ce
> > > > > tC
> > > > > omponent.java:331)\n\tat
> > > > > org.apache.solr.handler.component.FacetComponent.getFacetCount
> > > > > s(
> > > > > Fa
> > > > > ce
> > > > > tC
> > > > > omponent.java:295)\n\tat
> > > > > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(
> > > > > Mo
> > > > > re
> > > > > Li
> > > > > ke
> > > > > ThisHandler.java:240)\n\tat
> > > > > org.apache.solr.handler.RequestHandlerBase.handleRequest(Reque
> > > > > st
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > rBase.java:199)\n\tat
> > > > > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\ta
> > > > > t
> > > > > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java
> > > > > :7
> > > > > 09
> > > > > )\
> > > > > n\
> > > > > tat
> > > > > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:51
> > > > > 5)
> > > > > \n
> > > > > \t
> > > > > at
> > > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispat
> > > > > ch
> > > > > Fi
> > > > > lt
> > > > > er
> > > > > .java:377)\n\tat
> > > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispat
> > > > > ch
> > > > > Fi
> > > > > lt
> > > > > er
> > > > > .java:323)\n\tat
> > > > > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(
> > > > > Se
> > > > > rv
> > > > > le
> > > > > tH
> > > > > andler.java:1634)\n\tat
> > > > >
> > org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > > > > 533)\n\tat
> > > > >
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > > ja
> > > > > va:146)\n\tat
> > > > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
> > > > > ja
> > > > > va
> > > > > :548)\n\tat
> > > > >
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > > java:132)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scop
> > > > > ed
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:257)\n\tat
> > > > > org.eclipse.jetty.server.session.SessionHandler.doHandle(Sessi
> > > > > on
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:1595)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scop
> > > > > ed
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:255)\n\tat
> > > > > org.eclipse.jetty.server.handler.ContextHandler.doHandle(Conte
> > > > > xt
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:1317)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(Scope
> > > > > dH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:203)\n\tat
> > > > > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
> > > > > ja
> > > > > va
> > > > > :4
> > > > > 73)\n\tat
> > > > > org.eclipse.jetty.server.session.SessionHandler.doScope(Sessio
> > > > > nH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:1564)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(Scope
> > > > > dH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:201)\n\tat
> > > > > org.eclipse.jetty.server.handler.ContextHandler.doScope(Contex
> > > > > tH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:1219)\n\tat
> > > > >
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > > ja
> > > > > va:144)\n\tat
> > > > > org.eclipse.jetty.server.handler.ContextHandlerCollection.hand
> > > > > le
> > > > > (C
> > > > > on
> > > > > te
> > > > > xtHandlerCollection.java:219)\n\tat
> > > > > org.eclipse.jetty.server.handler.HandlerCollection.handle(Hand
> > > > > le
> > > > > rC
> > > > > ol
> > > > > le
> > > > > ction.java:126)\n\tat
> > > > >
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > > java:132)\n\tat
> > > > > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(Rewrit
> > > > > eH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:335)\n\tat
> > > > >
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > > java:132)\n\tat
> > > > > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > > > > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:3
> > > > > 52
> > > > > )\
> > > > > n\
> > > > > ta
> > > > > t
> > > > > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
> > > > > ja
> > > > > va
> > > > > :260)\n\tat
> > > > > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded
> > > > > (A
> > > > > bs
> > > > > tr
> > > > > ac
> > > > > tConnection.java:281)\n\tat
> > > > > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:1
> > > > > 02
> > > > > )\
> > > > > n\
> > > > > ta
> > > > > t
> > > > > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
> > > > > 11
> > > > > 8)
> > > > > \n
> > > > > \tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(
> > > > > Ea
> > > > > tW
> > > > > ha
> > > > > tY
> > > > > ouKill.java:333)\n\tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduc
> > > > > e(
> > > > > Ea
> > > > > tW
> > > > > ha
> > > > > tYouKill.java:310)\n\tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProdu
> > > > > ce
> > > > > (E
> > > > > at
> > > > > Wh
> > > > > atYouKill.java:168)\n\tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatW
> > > > > ha
> > > > > tY
> > > > > ou
> > > > > Ki
> > > > > ll.java:126)\n\tat
> > > > >
> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > > > > ru n(ReservedThreadExecutor.java:366)\n\tat
> > > > > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedTh
> > > > > re
> > > > > ad
> > > > > Po
> > > > > ol
> > > > > .java:762)\n\tat
> > > > >
> > org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > > > > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> > > > >
> > > > >     "code":500}}
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > In the above example I would like to facet on Journalnummer, 
> > > > > thus grouping several documents based on Journalnummer.
> > > > >
> > > > >
> > > > >
> > > > > Hope someone can help me, and thanks in advance.
> > > > >
> > > > >
> > > > >
> > > > > Best regards
> > > > >
> > > > >
> > > > >
> > > > > Martin
> > > > >
> > > > > Beskyttelse af dine personlige oplysninger er vigtig for os. 
> > > > > Her finder du KMD’s Privatlivspolitik 
> > > > > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan 
> > > > > vi
> > > > behandler oplysninger om dig.
> > > > >
> > > > > Protection of your personal data is important to us. Here you 
> > > > > can read KMD’s Privacy Policy 
> > > > > <http://www.kmd.net/Privacy-Policy>
> > > > > outlining how we process your personal data.
> > > > >
> > > > > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
> > > information.
> > > > > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig 
> > > > > venligst informere afsender om fejlen ved at bruge svarfunktionen.
> > > > > Samtidig beder vi dig slette e-mailen i dit system uden at 
> > > > > videresende eller
> > > > kopiere den.
> > > > > Selvom e-mailen og ethvert vedhæftet bilag efter vores 
> > > > > overbevisning er fri for virus og andre fejl, som kan påvirke 
> > > > > computeren eller it-systemet, hvori den modtages og læses, 
> > > > > åbnes den på modtagerens eget ansvar. Vi påtager os ikke noget 
> > > > > ansvar for tab og skade, som er opstået i forbindelse med at 
> > > > > modtage og
> > bruge e-mailen.
> > > > >
> > > > > Please note that this message may contain confidential information.
> > > > > If you have received this message by mistake, please inform 
> > > > > the sender of the mistake by sending a reply, then delete the 
> > > > > message from your system without making, distributing or 
> > > > > retaining any copies
> > > of it.
> > > > > Although we believe that the message and any attachments are 
> > > > > free from viruses and other errors that might affect the 
> > > > > computer or it-system where it is received and read, the 
> > > > > recipient opens the message at his or
> > > > her own risk.
> > > > > We assume no responsibility for any loss or damage arising 
> > > > > from the receipt or use of this message.
> > > > >
> > >
> >
>

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Dave, 

The problem is that we have different levels of metadata and documents. 
The documents are arranged such that we have a case for which there are multiple documents (files). When we use the mlt function, we do it on file-level, but it needs to be displayed at case level, which means that we need to group files that are connected to the same case. 

Hope this makes sense. 


Internal - KMD A/S

-----Original Message-----
From: Dave <ha...@gmail.com> 
Sent: 1. marts 2019 02:51
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

I’m more curious what you’d expect to see, and what possible benefit you could get from it

> On Feb 28, 2019, at 8:48 PM, Zheng Lin Edwin Yeo <ed...@gmail.com> wrote:
> 
> Hi Martin,
> 
> I have no idea on this, as the case has not been active for almost 2 years.
> Maybe I can try to follow up.
> 
> Faceting by default will show the list according to the number of 
> occurrences. But I'm not sure how it will affect the MLT score or how 
> it will be output when combine together, as it is not working 
> currently and there is no way to test.
> 
> Regards,
> Edwin
> 
>> On Thu, 28 Feb 2019 at 14:51, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:
>> 
>> Hi Edwin,
>> 
>> Ok that is nice to know. Do you know when this bug will get fixed?
>> 
>> By ordering I mean that MLT score the documents according to its 
>> similarity function (believe it is cosine similarity), and I don’t 
>> know how faceting will affect this score? Or ignore it all together?
>> 
>> Best regards
>> 
>> Martin
>> 
>> 
>> Internal - KMD A/S
>> 
>> -----Original Message-----
>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>> Sent: 28. februar 2019 06:19
>> To: solr-user@lucene.apache.org
>> Subject: Re: MLT and facetting
>> 
>> Hi Martin,
>> 
>> According to the JIRA, it says it is a bug, as it was working 
>> previously in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.
>> 
>> For the ordering of the documents, do you mean to sort them according 
>> to the criteria that you want?
>> 
>> Regards,
>> Edwin
>> 
>> On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>> wrote:
>> 
>>> Hi Edwin,
>>> 
>>> Thanks for your response. Are you sure it is a bug? Or is it not 
>>> meant to work together?
>>> After doing some thinking I do see a problem faceting a MLT-result.
>>> MLT-results have a clear ordering of the documents which will be 
>>> hard to maintain with facets. How will faceting MLT-results deal 
>>> with the ordering of the documents? Will the ordering just be ignored?
>>> 
>>> Best regards
>>> 
>>> Martin
>>> 
>>> 
>>> 
>>> Internal - KMD A/S
>>> 
>>> -----Original Message-----
>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>> Sent: 27. februar 2019 03:38
>>> To: solr-user@lucene.apache.org
>>> Subject: Re: MLT and facetting
>>> 
>>> Hi Martin,
>>> 
>>> I also get the same problem in Solr 7.7 if I turn on faceting in 
>>> /mlt requestHandler.
>>> 
>>> Found this issue in the JIRA:
>>> https://issues.apache.org/jira/browse/SOLR-7883
>>> Seems like it is a bug in Solr and it has not been resolved yet.
>>> 
>>> Regards,
>>> Edwin
>>> 
>>> On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>>> wrote:
>>> 
>>>> Hi Edwin,
>>>> 
>>>> Here it is:
>>>> 
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
>>>> 
>>>> 
>>>> -<lst name="defaults">
>>>> 
>>>> <str name="mlt.fl">text</str>
>>>> 
>>>> <str name="mlt.mintf">1</str>
>>>> 
>>>> <str name="mlt.mindf">1</str>
>>>> 
>>>> <str name="mlt.interestingTerms">true</str>
>>>> 
>>>> </lst>
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> Internal - KMD A/S
>>>> 
>>>> -----Original Message-----
>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>> Sent: 26. februar 2019 08:24
>>>> To: solr-user@lucene.apache.org
>>>> Subject: Re: MLT and facetting
>>>> 
>>>> Hi Martin,
>>>> 
>>>> What is your setting in your /mlt requestHandler in solrconfig.xml?
>>>> 
>>>> Regards,
>>>> Edwin
>>>> 
>>>> On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) 
>>>> <MH...@kmd.dk>
>>>> wrote:
>>>> 
>>>>> Hi Edwin,
>>>>> 
>>>>> Thanks for your response.
>>>>> 
>>>>> Yes you are right. It was simply the search parameters from Solr.
>>>>> 
>>>>> The query looks like this:
>>>>> 
>>>>> http://
>>>>> .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,
>>>>> Jo
>>>>> ur
>>>>> nalnummer&q=id:*6512815*
>>>>> 
>>>>> best regards,
>>>>> 
>>>>> Martin
>>>>> 
>>>>> 
>>>>> Internal - KMD A/S
>>>>> 
>>>>> -----Original Message-----
>>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>>> Sent: 26. februar 2019 03:54
>>>>> To: solr-user@lucene.apache.org
>>>>> Subject: Re: MLT and facetting
>>>>> 
>>>>> Hi Martin,
>>>>> 
>>>>> I think there are some pictures which are not being sent through 
>>>>> in the email.
>>>>> 
>>>>> Do send your query that you are using, and which version of Solr 
>>>>> you are using?
>>>>> 
>>>>> Regards,
>>>>> Edwin
>>>>> 
>>>>> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) 
>>>>> <MH...@kmd.dk>
>>>>> wrote:
>>>>> 
>>>>>> Hi,
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> I am trying to combine the mlt functionality with facets, but 
>>>>>> Solr throws
>>>>>> org.apache.solr.common.SolrException: ":"Unable to compute facet 
>>>>>> ranges, facet context is not set".
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> What I am trying to do is quite simple, find similar documents 
>>>>>> using mlt and group these using the facet parameter. When using 
>>>>>> mlt and facets separately everything works fine, but not when 
>>>>>> combining the
>>>>> functionality.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> {
>>>>>> 
>>>>>>  "responseHeader":{
>>>>>> 
>>>>>>    "status":500,
>>>>>> 
>>>>>>    "QTime":109},
>>>>>> 
>>>>>>  "match":{"numFound":1,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512815"  },
>>>>>> 
>>>>>>  "response":{"numFound":602234,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512816",
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6834653"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6202373"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6748105"
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00803",
>>>>>> 
>>>>>>        "id":"7402155"
>>>>>> 
>>>>>>  },
>>>>>> 
>>>>>>  "error":{
>>>>>> 
>>>>>>    "metadata":[
>>>>>> 
>>>>>>      "error-class","org.apache.solr.common.SolrException",
>>>>>> 
>>>>>> 
>>>>>> "root-error-class","org.apache.solr.common.SolrException"],
>>>>>> 
>>>>>>    "msg":"Unable to compute facet ranges, facet context is not 
>>>>>> set",
>>>>>> 
>>>>>>    "trace":"org.apache.solr.common.SolrException: Unable to 
>>>>>> compute facet ranges, facet context is not set\n\tat 
>>>>>> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRa
>>>>>> ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:331)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:295)\n\tat
>>>>>> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(Mo
>>>>>> re
>>>>>> Li
>>>>>> ke
>>>>>> ThisHandler.java:240)\n\tat
>>>>>> org.apache.solr.handler.RequestHandlerBase.handleRequest(Request
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> rBase.java:199)\n\tat
>>>>>> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:7
>>>>>> 09
>>>>>> )\
>>>>>> n\
>>>>>> tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)
>>>>>> \n
>>>>>> \t
>>>>>> at
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:377)\n\tat
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:323)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Se
>>>>>> rv
>>>>>> le
>>>>>> tH
>>>>>> andler.java:1634)\n\tat
>>>>>> 
>>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
>>>>>> 533)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:146)\n\tat
>>>>>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
>>>>>> ja
>>>>>> va
>>>>>> :548)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:257)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doHandle(Session
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1595)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:255)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doHandle(Context
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1317)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:203)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
>>>>>> ja
>>>>>> va
>>>>>> :4
>>>>>> 73)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1564)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:201)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1219)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:144)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle
>>>>>> (C
>>>>>> on
>>>>>> te
>>>>>> xtHandlerCollection.java:219)\n\tat
>>>>>> org.eclipse.jetty.server.handler.HandlerCollection.handle(Handle
>>>>>> rC
>>>>>> ol
>>>>>> le
>>>>>> ction.java:126)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:335)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
>>>>>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
>>>>>> ja
>>>>>> va
>>>>>> :260)\n\tat
>>>>>> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(A
>>>>>> bs
>>>>>> tr
>>>>>> ac
>>>>>> tConnection.java:281)\n\tat
>>>>>> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
>>>>>> 11
>>>>>> 8)
>>>>>> \n
>>>>>> \tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(Ea
>>>>>> tW
>>>>>> ha
>>>>>> tY
>>>>>> ouKill.java:333)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(
>>>>>> Ea
>>>>>> tW
>>>>>> ha
>>>>>> tYouKill.java:310)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce
>>>>>> (E
>>>>>> at
>>>>>> Wh
>>>>>> atYouKill.java:168)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWha
>>>>>> tY
>>>>>> ou
>>>>>> Ki
>>>>>> ll.java:126)\n\tat
>>>>>> 
>> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
>>>>>> ru n(ReservedThreadExecutor.java:366)\n\tat
>>>>>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThre
>>>>>> ad
>>>>>> Po
>>>>>> ol
>>>>>> .java:762)\n\tat
>>>>>> 
>>> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
>>>>>> java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>>>>>> 
>>>>>>    "code":500}}
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> In the above example I would like to facet on Journalnummer, thus 
>>>>>> grouping several documents based on Journalnummer.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Hope someone can help me, and thanks in advance.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Best regards
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Martin
>>>>>> 
>>>>>> Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
>>>>>> finder du KMD’s Privatlivspolitik 
>>>>>> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
>>>>> behandler oplysninger om dig.
>>>>>> 
>>>>>> Protection of your personal data is important to us. Here you can 
>>>>>> read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy>
>>>>>> outlining how we process your personal data.
>>>>>> 
>>>>>> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
>>>> information.
>>>>>> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig 
>>>>>> venligst informere afsender om fejlen ved at bruge svarfunktionen.
>>>>>> Samtidig beder vi dig slette e-mailen i dit system uden at 
>>>>>> videresende eller
>>>>> kopiere den.
>>>>>> Selvom e-mailen og ethvert vedhæftet bilag efter vores 
>>>>>> overbevisning er fri for virus og andre fejl, som kan påvirke 
>>>>>> computeren eller it-systemet, hvori den modtages og læses, åbnes 
>>>>>> den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar 
>>>>>> for tab og skade, som er opstået i forbindelse med at modtage og
>>> bruge e-mailen.
>>>>>> 
>>>>>> Please note that this message may contain confidential information.
>>>>>> If you have received this message by mistake, please inform the 
>>>>>> sender of the mistake by sending a reply, then delete the message 
>>>>>> from your system without making, distributing or retaining any 
>>>>>> copies
>>>> of it.
>>>>>> Although we believe that the message and any attachments are free 
>>>>>> from viruses and other errors that might affect the computer or 
>>>>>> it-system where it is received and read, the recipient opens the 
>>>>>> message at his or
>>>>> her own risk.
>>>>>> We assume no responsibility for any loss or damage arising from 
>>>>>> the receipt or use of this message.
>>>>>> 
>>>> 
>>> 
>> 

Re: MLT and facetting

Posted by Dave <ha...@gmail.com>.
I’m more curious what you’d expect to see, and what possible benefit you could get from it

> On Feb 28, 2019, at 8:48 PM, Zheng Lin Edwin Yeo <ed...@gmail.com> wrote:
> 
> Hi Martin,
> 
> I have no idea on this, as the case has not been active for almost 2 years.
> Maybe I can try to follow up.
> 
> Faceting by default will show the list according to the number of
> occurrences. But I'm not sure how it will affect the MLT score or how it
> will be output when combine together, as it is not working currently and
> there is no way to test.
> 
> Regards,
> Edwin
> 
>> On Thu, 28 Feb 2019 at 14:51, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:
>> 
>> Hi Edwin,
>> 
>> Ok that is nice to know. Do you know when this bug will get fixed?
>> 
>> By ordering I mean that MLT score the documents according to its
>> similarity function (believe it is cosine similarity), and I don’t know how
>> faceting will affect this score? Or ignore it all together?
>> 
>> Best regards
>> 
>> Martin
>> 
>> 
>> Internal - KMD A/S
>> 
>> -----Original Message-----
>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>> Sent: 28. februar 2019 06:19
>> To: solr-user@lucene.apache.org
>> Subject: Re: MLT and facetting
>> 
>> Hi Martin,
>> 
>> According to the JIRA, it says it is a bug, as it was working previously
>> in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.
>> 
>> For the ordering of the documents, do you mean to sort them according to
>> the criteria that you want?
>> 
>> Regards,
>> Edwin
>> 
>> On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>> wrote:
>> 
>>> Hi Edwin,
>>> 
>>> Thanks for your response. Are you sure it is a bug? Or is it not meant
>>> to work together?
>>> After doing some thinking I do see a problem faceting a MLT-result.
>>> MLT-results have a clear ordering of the documents which will be hard
>>> to maintain with facets. How will faceting MLT-results deal with the
>>> ordering of the documents? Will the ordering just be ignored?
>>> 
>>> Best regards
>>> 
>>> Martin
>>> 
>>> 
>>> 
>>> Internal - KMD A/S
>>> 
>>> -----Original Message-----
>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>> Sent: 27. februar 2019 03:38
>>> To: solr-user@lucene.apache.org
>>> Subject: Re: MLT and facetting
>>> 
>>> Hi Martin,
>>> 
>>> I also get the same problem in Solr 7.7 if I turn on faceting in /mlt
>>> requestHandler.
>>> 
>>> Found this issue in the JIRA:
>>> https://issues.apache.org/jira/browse/SOLR-7883
>>> Seems like it is a bug in Solr and it has not been resolved yet.
>>> 
>>> Regards,
>>> Edwin
>>> 
>>> On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>>> wrote:
>>> 
>>>> Hi Edwin,
>>>> 
>>>> Here it is:
>>>> 
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
>>>> 
>>>> 
>>>> -<lst name="defaults">
>>>> 
>>>> <str name="mlt.fl">text</str>
>>>> 
>>>> <str name="mlt.mintf">1</str>
>>>> 
>>>> <str name="mlt.mindf">1</str>
>>>> 
>>>> <str name="mlt.interestingTerms">true</str>
>>>> 
>>>> </lst>
>>>> 
>>>> </requestHandler>
>>>> 
>>>> 
>>>> Internal - KMD A/S
>>>> 
>>>> -----Original Message-----
>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>> Sent: 26. februar 2019 08:24
>>>> To: solr-user@lucene.apache.org
>>>> Subject: Re: MLT and facetting
>>>> 
>>>> Hi Martin,
>>>> 
>>>> What is your setting in your /mlt requestHandler in solrconfig.xml?
>>>> 
>>>> Regards,
>>>> Edwin
>>>> 
>>>> On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
>>>> wrote:
>>>> 
>>>>> Hi Edwin,
>>>>> 
>>>>> Thanks for your response.
>>>>> 
>>>>> Yes you are right. It was simply the search parameters from Solr.
>>>>> 
>>>>> The query looks like this:
>>>>> 
>>>>> http://
>>>>> .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,
>>>>> Jo
>>>>> ur
>>>>> nalnummer&q=id:*6512815*
>>>>> 
>>>>> best regards,
>>>>> 
>>>>> Martin
>>>>> 
>>>>> 
>>>>> Internal - KMD A/S
>>>>> 
>>>>> -----Original Message-----
>>>>> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
>>>>> Sent: 26. februar 2019 03:54
>>>>> To: solr-user@lucene.apache.org
>>>>> Subject: Re: MLT and facetting
>>>>> 
>>>>> Hi Martin,
>>>>> 
>>>>> I think there are some pictures which are not being sent through
>>>>> in the email.
>>>>> 
>>>>> Do send your query that you are using, and which version of Solr
>>>>> you are using?
>>>>> 
>>>>> Regards,
>>>>> Edwin
>>>>> 
>>>>> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ)
>>>>> <MH...@kmd.dk>
>>>>> wrote:
>>>>> 
>>>>>> Hi,
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> I am trying to combine the mlt functionality with facets, but
>>>>>> Solr throws
>>>>>> org.apache.solr.common.SolrException: ":"Unable to compute facet
>>>>>> ranges, facet context is not set".
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> What I am trying to do is quite simple, find similar documents
>>>>>> using mlt and group these using the facet parameter. When using
>>>>>> mlt and facets separately everything works fine, but not when
>>>>>> combining the
>>>>> functionality.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> {
>>>>>> 
>>>>>>  "responseHeader":{
>>>>>> 
>>>>>>    "status":500,
>>>>>> 
>>>>>>    "QTime":109},
>>>>>> 
>>>>>>  "match":{"numFound":1,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512815"  },
>>>>>> 
>>>>>>  "response":{"numFound":602234,"start":0,"docs":[
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6512816",
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00759",
>>>>>> 
>>>>>>        "id":"6834653"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6202373"
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00739",
>>>>>> 
>>>>>>        "id":"6748105"
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>>      {
>>>>>> 
>>>>>>        "Journalnummer":" 00803",
>>>>>> 
>>>>>>        "id":"7402155"
>>>>>> 
>>>>>>  },
>>>>>> 
>>>>>>  "error":{
>>>>>> 
>>>>>>    "metadata":[
>>>>>> 
>>>>>>      "error-class","org.apache.solr.common.SolrException",
>>>>>> 
>>>>>> 
>>>>>> "root-error-class","org.apache.solr.common.SolrException"],
>>>>>> 
>>>>>>    "msg":"Unable to compute facet ranges, facet context is not
>>>>>> set",
>>>>>> 
>>>>>>    "trace":"org.apache.solr.common.SolrException: Unable to
>>>>>> compute facet ranges, facet context is not set\n\tat
>>>>>> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRa
>>>>>> ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:331)\n\tat
>>>>>> org.apache.solr.handler.component.FacetComponent.getFacetCounts(
>>>>>> Fa
>>>>>> ce
>>>>>> tC
>>>>>> omponent.java:295)\n\tat
>>>>>> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(Mo
>>>>>> re
>>>>>> Li
>>>>>> ke
>>>>>> ThisHandler.java:240)\n\tat
>>>>>> org.apache.solr.handler.RequestHandlerBase.handleRequest(Request
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> rBase.java:199)\n\tat
>>>>>> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:7
>>>>>> 09
>>>>>> )\
>>>>>> n\
>>>>>> tat
>>>>>> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)
>>>>>> \n
>>>>>> \t
>>>>>> at
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:377)\n\tat
>>>>>> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
>>>>>> Fi
>>>>>> lt
>>>>>> er
>>>>>> .java:323)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Se
>>>>>> rv
>>>>>> le
>>>>>> tH
>>>>>> andler.java:1634)\n\tat
>>>>>> 
>>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
>>>>>> 533)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:146)\n\tat
>>>>>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
>>>>>> ja
>>>>>> va
>>>>>> :548)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:257)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doHandle(Session
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1595)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:255)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doHandle(Context
>>>>>> Ha
>>>>>> nd
>>>>>> le
>>>>>> r.java:1317)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:203)\n\tat
>>>>>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
>>>>>> ja
>>>>>> va
>>>>>> :4
>>>>>> 73)\n\tat
>>>>>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1564)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:201)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:1219)\n\tat
>>>>>> 
>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
>>>>>> ja
>>>>>> va:144)\n\tat
>>>>>> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle
>>>>>> (C
>>>>>> on
>>>>>> te
>>>>>> xtHandlerCollection.java:219)\n\tat
>>>>>> org.eclipse.jetty.server.handler.HandlerCollection.handle(Handle
>>>>>> rC
>>>>>> ol
>>>>>> le
>>>>>> ction.java:126)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteH
>>>>>> an
>>>>>> dl
>>>>>> er
>>>>>> .java:335)\n\tat
>>>>>> 
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
>>>>>> java:132)\n\tat
>>>>>> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
>>>>>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
>>>>>> ja
>>>>>> va
>>>>>> :260)\n\tat
>>>>>> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(A
>>>>>> bs
>>>>>> tr
>>>>>> ac
>>>>>> tConnection.java:281)\n\tat
>>>>>> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102
>>>>>> )\
>>>>>> n\
>>>>>> ta
>>>>>> t
>>>>>> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
>>>>>> 11
>>>>>> 8)
>>>>>> \n
>>>>>> \tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(Ea
>>>>>> tW
>>>>>> ha
>>>>>> tY
>>>>>> ouKill.java:333)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(
>>>>>> Ea
>>>>>> tW
>>>>>> ha
>>>>>> tYouKill.java:310)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce
>>>>>> (E
>>>>>> at
>>>>>> Wh
>>>>>> atYouKill.java:168)\n\tat
>>>>>> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWha
>>>>>> tY
>>>>>> ou
>>>>>> Ki
>>>>>> ll.java:126)\n\tat
>>>>>> 
>> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
>>>>>> ru n(ReservedThreadExecutor.java:366)\n\tat
>>>>>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThre
>>>>>> ad
>>>>>> Po
>>>>>> ol
>>>>>> .java:762)\n\tat
>>>>>> 
>>> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
>>>>>> java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>>>>>> 
>>>>>>    "code":500}}
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> In the above example I would like to facet on Journalnummer,
>>>>>> thus grouping several documents based on Journalnummer.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Hope someone can help me, and thanks in advance.
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Best regards
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Martin
>>>>>> 
>>>>>> Beskyttelse af dine personlige oplysninger er vigtig for os. Her
>>>>>> finder du KMD’s Privatlivspolitik
>>>>>> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
>>>>> behandler oplysninger om dig.
>>>>>> 
>>>>>> Protection of your personal data is important to us. Here you
>>>>>> can read KMD’s Privacy Policy
>>>>>> <http://www.kmd.net/Privacy-Policy>
>>>>>> outlining how we process your personal data.
>>>>>> 
>>>>>> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
>>>> information.
>>>>>> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig
>>>>>> venligst informere afsender om fejlen ved at bruge svarfunktionen.
>>>>>> Samtidig beder vi dig slette e-mailen i dit system uden at
>>>>>> videresende eller
>>>>> kopiere den.
>>>>>> Selvom e-mailen og ethvert vedhæftet bilag efter vores
>>>>>> overbevisning er fri for virus og andre fejl, som kan påvirke
>>>>>> computeren eller it-systemet, hvori den modtages og læses, åbnes
>>>>>> den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar
>>>>>> for tab og skade, som er opstået i forbindelse med at modtage og
>>> bruge e-mailen.
>>>>>> 
>>>>>> Please note that this message may contain confidential information.
>>>>>> If you have received this message by mistake, please inform the
>>>>>> sender of the mistake by sending a reply, then delete the
>>>>>> message from your system without making, distributing or
>>>>>> retaining any copies
>>>> of it.
>>>>>> Although we believe that the message and any attachments are
>>>>>> free from viruses and other errors that might affect the
>>>>>> computer or it-system where it is received and read, the
>>>>>> recipient opens the message at his or
>>>>> her own risk.
>>>>>> We assume no responsibility for any loss or damage arising from
>>>>>> the receipt or use of this message.
>>>>>> 
>>>> 
>>> 
>> 

Re: MLT and facetting

Posted by Zheng Lin Edwin Yeo <ed...@gmail.com>.
Hi Martin,

I have no idea on this, as the case has not been active for almost 2 years.
Maybe I can try to follow up.

Faceting by default will show the list according to the number of
occurrences. But I'm not sure how it will affect the MLT score or how it
will be output when combine together, as it is not working currently and
there is no way to test.

Regards,
Edwin

On Thu, 28 Feb 2019 at 14:51, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Ok that is nice to know. Do you know when this bug will get fixed?
>
> By ordering I mean that MLT score the documents according to its
> similarity function (believe it is cosine similarity), and I don’t know how
> faceting will affect this score? Or ignore it all together?
>
> Best regards
>
> Martin
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 28. februar 2019 06:19
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> According to the JIRA, it says it is a bug, as it was working previously
> in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.
>
> For the ordering of the documents, do you mean to sort them according to
> the criteria that you want?
>
> Regards,
> Edwin
>
> On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi Edwin,
> >
> > Thanks for your response. Are you sure it is a bug? Or is it not meant
> > to work together?
> > After doing some thinking I do see a problem faceting a MLT-result.
> > MLT-results have a clear ordering of the documents which will be hard
> > to maintain with facets. How will faceting MLT-results deal with the
> > ordering of the documents? Will the ordering just be ignored?
> >
> > Best regards
> >
> > Martin
> >
> >
> >
> > Internal - KMD A/S
> >
> > -----Original Message-----
> > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > Sent: 27. februar 2019 03:38
> > To: solr-user@lucene.apache.org
> > Subject: Re: MLT and facetting
> >
> > Hi Martin,
> >
> > I also get the same problem in Solr 7.7 if I turn on faceting in /mlt
> > requestHandler.
> >
> > Found this issue in the JIRA:
> > https://issues.apache.org/jira/browse/SOLR-7883
> > Seems like it is a bug in Solr and it has not been resolved yet.
> >
> > Regards,
> > Edwin
> >
> > On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > wrote:
> >
> > > Hi Edwin,
> > >
> > > Here it is:
> > >
> > >
> > > </requestHandler>
> > >
> > >
> > > -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
> > >
> > >
> > > -<lst name="defaults">
> > >
> > > <str name="mlt.fl">text</str>
> > >
> > > <str name="mlt.mintf">1</str>
> > >
> > > <str name="mlt.mindf">1</str>
> > >
> > > <str name="mlt.interestingTerms">true</str>
> > >
> > > </lst>
> > >
> > > </requestHandler>
> > >
> > >
> > > Internal - KMD A/S
> > >
> > > -----Original Message-----
> > > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > > Sent: 26. februar 2019 08:24
> > > To: solr-user@lucene.apache.org
> > > Subject: Re: MLT and facetting
> > >
> > > Hi Martin,
> > >
> > > What is your setting in your /mlt requestHandler in solrconfig.xml?
> > >
> > > Regards,
> > > Edwin
> > >
> > > On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > > wrote:
> > >
> > > > Hi Edwin,
> > > >
> > > > Thanks for your response.
> > > >
> > > > Yes you are right. It was simply the search parameters from Solr.
> > > >
> > > > The query looks like this:
> > > >
> > > > http://
> > > > .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,
> > > > Jo
> > > > ur
> > > > nalnummer&q=id:*6512815*
> > > >
> > > > best regards,
> > > >
> > > > Martin
> > > >
> > > >
> > > > Internal - KMD A/S
> > > >
> > > > -----Original Message-----
> > > > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > > > Sent: 26. februar 2019 03:54
> > > > To: solr-user@lucene.apache.org
> > > > Subject: Re: MLT and facetting
> > > >
> > > > Hi Martin,
> > > >
> > > > I think there are some pictures which are not being sent through
> > > > in the email.
> > > >
> > > > Do send your query that you are using, and which version of Solr
> > > > you are using?
> > > >
> > > > Regards,
> > > > Edwin
> > > >
> > > > On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ)
> > > > <MH...@kmd.dk>
> > > > wrote:
> > > >
> > > > > Hi,
> > > > >
> > > > >
> > > > >
> > > > > I am trying to combine the mlt functionality with facets, but
> > > > > Solr throws
> > > > > org.apache.solr.common.SolrException: ":"Unable to compute facet
> > > > > ranges, facet context is not set".
> > > > >
> > > > >
> > > > >
> > > > > What I am trying to do is quite simple, find similar documents
> > > > > using mlt and group these using the facet parameter. When using
> > > > > mlt and facets separately everything works fine, but not when
> > > > > combining the
> > > > functionality.
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > {
> > > > >
> > > > >   "responseHeader":{
> > > > >
> > > > >     "status":500,
> > > > >
> > > > >     "QTime":109},
> > > > >
> > > > >   "match":{"numFound":1,"start":0,"docs":[
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00759",
> > > > >
> > > > >         "id":"6512815"  },
> > > > >
> > > > >   "response":{"numFound":602234,"start":0,"docs":[
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00759",
> > > > >
> > > > >         "id":"6512816",
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00759",
> > > > >
> > > > >         "id":"6834653"
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00739",
> > > > >
> > > > >         "id":"6202373"
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00739",
> > > > >
> > > > >         "id":"6748105"
> > > > >
> > > > >
> > > > >
> > > > >       {
> > > > >
> > > > >         "Journalnummer":" 00803",
> > > > >
> > > > >         "id":"7402155"
> > > > >
> > > > >   },
> > > > >
> > > > >   "error":{
> > > > >
> > > > >     "metadata":[
> > > > >
> > > > >       "error-class","org.apache.solr.common.SolrException",
> > > > >
> > > > >
> > > > > "root-error-class","org.apache.solr.common.SolrException"],
> > > > >
> > > > >     "msg":"Unable to compute facet ranges, facet context is not
> > > > > set",
> > > > >
> > > > >     "trace":"org.apache.solr.common.SolrException: Unable to
> > > > > compute facet ranges, facet context is not set\n\tat
> > > > > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRa
> > > > > ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
> > > > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(
> > > > > Fa
> > > > > ce
> > > > > tC
> > > > > omponent.java:331)\n\tat
> > > > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(
> > > > > Fa
> > > > > ce
> > > > > tC
> > > > > omponent.java:295)\n\tat
> > > > > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(Mo
> > > > > re
> > > > > Li
> > > > > ke
> > > > > ThisHandler.java:240)\n\tat
> > > > > org.apache.solr.handler.RequestHandlerBase.handleRequest(Request
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > rBase.java:199)\n\tat
> > > > > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > > > > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:7
> > > > > 09
> > > > > )\
> > > > > n\
> > > > > tat
> > > > > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)
> > > > > \n
> > > > > \t
> > > > > at
> > > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
> > > > > Fi
> > > > > lt
> > > > > er
> > > > > .java:377)\n\tat
> > > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
> > > > > Fi
> > > > > lt
> > > > > er
> > > > > .java:323)\n\tat
> > > > > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Se
> > > > > rv
> > > > > le
> > > > > tH
> > > > > andler.java:1634)\n\tat
> > > > >
> > org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > > > > 533)\n\tat
> > > > >
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > > ja
> > > > > va:146)\n\tat
> > > > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
> > > > > ja
> > > > > va
> > > > > :548)\n\tat
> > > > >
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > > java:132)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:257)\n\tat
> > > > > org.eclipse.jetty.server.session.SessionHandler.doHandle(Session
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:1595)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:255)\n\tat
> > > > > org.eclipse.jetty.server.handler.ContextHandler.doHandle(Context
> > > > > Ha
> > > > > nd
> > > > > le
> > > > > r.java:1317)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:203)\n\tat
> > > > > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
> > > > > ja
> > > > > va
> > > > > :4
> > > > > 73)\n\tat
> > > > > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:1564)\n\tat
> > > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:201)\n\tat
> > > > > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:1219)\n\tat
> > > > >
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > > ja
> > > > > va:144)\n\tat
> > > > > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle
> > > > > (C
> > > > > on
> > > > > te
> > > > > xtHandlerCollection.java:219)\n\tat
> > > > > org.eclipse.jetty.server.handler.HandlerCollection.handle(Handle
> > > > > rC
> > > > > ol
> > > > > le
> > > > > ction.java:126)\n\tat
> > > > >
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > > java:132)\n\tat
> > > > > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteH
> > > > > an
> > > > > dl
> > > > > er
> > > > > .java:335)\n\tat
> > > > >
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > > java:132)\n\tat
> > > > > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > > > > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352
> > > > > )\
> > > > > n\
> > > > > ta
> > > > > t
> > > > > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
> > > > > ja
> > > > > va
> > > > > :260)\n\tat
> > > > > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(A
> > > > > bs
> > > > > tr
> > > > > ac
> > > > > tConnection.java:281)\n\tat
> > > > > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102
> > > > > )\
> > > > > n\
> > > > > ta
> > > > > t
> > > > > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
> > > > > 11
> > > > > 8)
> > > > > \n
> > > > > \tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(Ea
> > > > > tW
> > > > > ha
> > > > > tY
> > > > > ouKill.java:333)\n\tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(
> > > > > Ea
> > > > > tW
> > > > > ha
> > > > > tYouKill.java:310)\n\tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce
> > > > > (E
> > > > > at
> > > > > Wh
> > > > > atYouKill.java:168)\n\tat
> > > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWha
> > > > > tY
> > > > > ou
> > > > > Ki
> > > > > ll.java:126)\n\tat
> > > > >
> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > > > > ru n(ReservedThreadExecutor.java:366)\n\tat
> > > > > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThre
> > > > > ad
> > > > > Po
> > > > > ol
> > > > > .java:762)\n\tat
> > > > >
> > org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > > > > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> > > > >
> > > > >     "code":500}}
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > In the above example I would like to facet on Journalnummer,
> > > > > thus grouping several documents based on Journalnummer.
> > > > >
> > > > >
> > > > >
> > > > > Hope someone can help me, and thanks in advance.
> > > > >
> > > > >
> > > > >
> > > > > Best regards
> > > > >
> > > > >
> > > > >
> > > > > Martin
> > > > >
> > > > > Beskyttelse af dine personlige oplysninger er vigtig for os. Her
> > > > > finder du KMD’s Privatlivspolitik
> > > > > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> > > > behandler oplysninger om dig.
> > > > >
> > > > > Protection of your personal data is important to us. Here you
> > > > > can read KMD’s Privacy Policy
> > > > > <http://www.kmd.net/Privacy-Policy>
> > > > > outlining how we process your personal data.
> > > > >
> > > > > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
> > > information.
> > > > > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig
> > > > > venligst informere afsender om fejlen ved at bruge svarfunktionen.
> > > > > Samtidig beder vi dig slette e-mailen i dit system uden at
> > > > > videresende eller
> > > > kopiere den.
> > > > > Selvom e-mailen og ethvert vedhæftet bilag efter vores
> > > > > overbevisning er fri for virus og andre fejl, som kan påvirke
> > > > > computeren eller it-systemet, hvori den modtages og læses, åbnes
> > > > > den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar
> > > > > for tab og skade, som er opstået i forbindelse med at modtage og
> > bruge e-mailen.
> > > > >
> > > > > Please note that this message may contain confidential information.
> > > > > If you have received this message by mistake, please inform the
> > > > > sender of the mistake by sending a reply, then delete the
> > > > > message from your system without making, distributing or
> > > > > retaining any copies
> > > of it.
> > > > > Although we believe that the message and any attachments are
> > > > > free from viruses and other errors that might affect the
> > > > > computer or it-system where it is received and read, the
> > > > > recipient opens the message at his or
> > > > her own risk.
> > > > > We assume no responsibility for any loss or damage arising from
> > > > > the receipt or use of this message.
> > > > >
> > >
> >
>

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Edwin, 

Ok that is nice to know. Do you know when this bug will get fixed? 

By ordering I mean that MLT score the documents according to its similarity function (believe it is cosine similarity), and I don’t know how faceting will affect this score? Or ignore it all together? 

Best regards

Martin 


Internal - KMD A/S

-----Original Message-----
From: Zheng Lin Edwin Yeo <ed...@gmail.com> 
Sent: 28. februar 2019 06:19
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Hi Martin,

According to the JIRA, it says it is a bug, as it was working previously in Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.

For the ordering of the documents, do you mean to sort them according to the criteria that you want?

Regards,
Edwin

On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Thanks for your response. Are you sure it is a bug? Or is it not meant 
> to work together?
> After doing some thinking I do see a problem faceting a MLT-result.
> MLT-results have a clear ordering of the documents which will be hard 
> to maintain with facets. How will faceting MLT-results deal with the 
> ordering of the documents? Will the ordering just be ignored?
>
> Best regards
>
> Martin
>
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 27. februar 2019 03:38
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> I also get the same problem in Solr 7.7 if I turn on faceting in /mlt 
> requestHandler.
>
> Found this issue in the JIRA:
> https://issues.apache.org/jira/browse/SOLR-7883
> Seems like it is a bug in Solr and it has not been resolved yet.
>
> Regards,
> Edwin
>
> On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi Edwin,
> >
> > Here it is:
> >
> >
> > </requestHandler>
> >
> >
> > -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
> >
> >
> > -<lst name="defaults">
> >
> > <str name="mlt.fl">text</str>
> >
> > <str name="mlt.mintf">1</str>
> >
> > <str name="mlt.mindf">1</str>
> >
> > <str name="mlt.interestingTerms">true</str>
> >
> > </lst>
> >
> > </requestHandler>
> >
> >
> > Internal - KMD A/S
> >
> > -----Original Message-----
> > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > Sent: 26. februar 2019 08:24
> > To: solr-user@lucene.apache.org
> > Subject: Re: MLT and facetting
> >
> > Hi Martin,
> >
> > What is your setting in your /mlt requestHandler in solrconfig.xml?
> >
> > Regards,
> > Edwin
> >
> > On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > wrote:
> >
> > > Hi Edwin,
> > >
> > > Thanks for your response.
> > >
> > > Yes you are right. It was simply the search parameters from Solr.
> > >
> > > The query looks like this:
> > >
> > > http://
> > > .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,
> > > Jo
> > > ur
> > > nalnummer&q=id:*6512815*
> > >
> > > best regards,
> > >
> > > Martin
> > >
> > >
> > > Internal - KMD A/S
> > >
> > > -----Original Message-----
> > > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > > Sent: 26. februar 2019 03:54
> > > To: solr-user@lucene.apache.org
> > > Subject: Re: MLT and facetting
> > >
> > > Hi Martin,
> > >
> > > I think there are some pictures which are not being sent through 
> > > in the email.
> > >
> > > Do send your query that you are using, and which version of Solr 
> > > you are using?
> > >
> > > Regards,
> > > Edwin
> > >
> > > On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) 
> > > <MH...@kmd.dk>
> > > wrote:
> > >
> > > > Hi,
> > > >
> > > >
> > > >
> > > > I am trying to combine the mlt functionality with facets, but 
> > > > Solr throws
> > > > org.apache.solr.common.SolrException: ":"Unable to compute facet 
> > > > ranges, facet context is not set".
> > > >
> > > >
> > > >
> > > > What I am trying to do is quite simple, find similar documents 
> > > > using mlt and group these using the facet parameter. When using 
> > > > mlt and facets separately everything works fine, but not when 
> > > > combining the
> > > functionality.
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > {
> > > >
> > > >   "responseHeader":{
> > > >
> > > >     "status":500,
> > > >
> > > >     "QTime":109},
> > > >
> > > >   "match":{"numFound":1,"start":0,"docs":[
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00759",
> > > >
> > > >         "id":"6512815"  },
> > > >
> > > >   "response":{"numFound":602234,"start":0,"docs":[
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00759",
> > > >
> > > >         "id":"6512816",
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00759",
> > > >
> > > >         "id":"6834653"
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00739",
> > > >
> > > >         "id":"6202373"
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00739",
> > > >
> > > >         "id":"6748105"
> > > >
> > > >
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00803",
> > > >
> > > >         "id":"7402155"
> > > >
> > > >   },
> > > >
> > > >   "error":{
> > > >
> > > >     "metadata":[
> > > >
> > > >       "error-class","org.apache.solr.common.SolrException",
> > > >
> > > >       
> > > > "root-error-class","org.apache.solr.common.SolrException"],
> > > >
> > > >     "msg":"Unable to compute facet ranges, facet context is not 
> > > > set",
> > > >
> > > >     "trace":"org.apache.solr.common.SolrException: Unable to 
> > > > compute facet ranges, facet context is not set\n\tat 
> > > > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRa
> > > > ng eC ou nts(RangeFacetProcessor.java:66)\n\tat
> > > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(
> > > > Fa
> > > > ce
> > > > tC
> > > > omponent.java:331)\n\tat
> > > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(
> > > > Fa
> > > > ce
> > > > tC
> > > > omponent.java:295)\n\tat
> > > > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(Mo
> > > > re
> > > > Li
> > > > ke
> > > > ThisHandler.java:240)\n\tat
> > > > org.apache.solr.handler.RequestHandlerBase.handleRequest(Request
> > > > Ha
> > > > nd
> > > > le
> > > > rBase.java:199)\n\tat
> > > > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > > > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:7
> > > > 09
> > > > )\
> > > > n\
> > > > tat
> > > > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)
> > > > \n
> > > > \t
> > > > at
> > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
> > > > Fi
> > > > lt
> > > > er
> > > > .java:377)\n\tat
> > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatch
> > > > Fi
> > > > lt
> > > > er
> > > > .java:323)\n\tat
> > > > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Se
> > > > rv
> > > > le
> > > > tH
> > > > andler.java:1634)\n\tat
> > > >
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > > > 533)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > ja
> > > > va:146)\n\tat
> > > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
> > > > ja
> > > > va
> > > > :548)\n\tat
> > > >
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > java:132)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
> > > > Ha
> > > > nd
> > > > le
> > > > r.java:257)\n\tat
> > > > org.eclipse.jetty.server.session.SessionHandler.doHandle(Session
> > > > Ha
> > > > nd
> > > > le
> > > > r.java:1595)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(Scoped
> > > > Ha
> > > > nd
> > > > le
> > > > r.java:255)\n\tat
> > > > org.eclipse.jetty.server.handler.ContextHandler.doHandle(Context
> > > > Ha
> > > > nd
> > > > le
> > > > r.java:1317)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
> > > > an
> > > > dl
> > > > er
> > > > .java:203)\n\tat
> > > > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.
> > > > ja
> > > > va
> > > > :4
> > > > 73)\n\tat
> > > > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionH
> > > > an
> > > > dl
> > > > er
> > > > .java:1564)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedH
> > > > an
> > > > dl
> > > > er
> > > > .java:201)\n\tat
> > > > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextH
> > > > an
> > > > dl
> > > > er
> > > > .java:1219)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > ja
> > > > va:144)\n\tat
> > > > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle
> > > > (C
> > > > on
> > > > te
> > > > xtHandlerCollection.java:219)\n\tat
> > > > org.eclipse.jetty.server.handler.HandlerCollection.handle(Handle
> > > > rC
> > > > ol
> > > > le
> > > > ction.java:126)\n\tat
> > > >
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > java:132)\n\tat
> > > > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteH
> > > > an
> > > > dl
> > > > er
> > > > .java:335)\n\tat
> > > >
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > java:132)\n\tat
> > > > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > > > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352
> > > > )\
> > > > n\
> > > > ta
> > > > t
> > > > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
> > > > ja
> > > > va
> > > > :260)\n\tat
> > > > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(A
> > > > bs
> > > > tr
> > > > ac
> > > > tConnection.java:281)\n\tat
> > > > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102
> > > > )\
> > > > n\
> > > > ta
> > > > t
> > > > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:
> > > > 11
> > > > 8)
> > > > \n
> > > > \tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(Ea
> > > > tW
> > > > ha
> > > > tY
> > > > ouKill.java:333)\n\tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(
> > > > Ea
> > > > tW
> > > > ha
> > > > tYouKill.java:310)\n\tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce
> > > > (E
> > > > at
> > > > Wh
> > > > atYouKill.java:168)\n\tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWha
> > > > tY
> > > > ou
> > > > Ki
> > > > ll.java:126)\n\tat
> > > > org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > > > ru n(ReservedThreadExecutor.java:366)\n\tat
> > > > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThre
> > > > ad
> > > > Po
> > > > ol
> > > > .java:762)\n\tat
> > > >
> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > > > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> > > >
> > > >     "code":500}}
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > In the above example I would like to facet on Journalnummer, 
> > > > thus grouping several documents based on Journalnummer.
> > > >
> > > >
> > > >
> > > > Hope someone can help me, and thanks in advance.
> > > >
> > > >
> > > >
> > > > Best regards
> > > >
> > > >
> > > >
> > > > Martin
> > > >
> > > > Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
> > > > finder du KMD’s Privatlivspolitik 
> > > > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> > > behandler oplysninger om dig.
> > > >
> > > > Protection of your personal data is important to us. Here you 
> > > > can read KMD’s Privacy Policy 
> > > > <http://www.kmd.net/Privacy-Policy>
> > > > outlining how we process your personal data.
> > > >
> > > > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
> > information.
> > > > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig 
> > > > venligst informere afsender om fejlen ved at bruge svarfunktionen.
> > > > Samtidig beder vi dig slette e-mailen i dit system uden at 
> > > > videresende eller
> > > kopiere den.
> > > > Selvom e-mailen og ethvert vedhæftet bilag efter vores 
> > > > overbevisning er fri for virus og andre fejl, som kan påvirke 
> > > > computeren eller it-systemet, hvori den modtages og læses, åbnes 
> > > > den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar 
> > > > for tab og skade, som er opstået i forbindelse med at modtage og
> bruge e-mailen.
> > > >
> > > > Please note that this message may contain confidential information.
> > > > If you have received this message by mistake, please inform the 
> > > > sender of the mistake by sending a reply, then delete the 
> > > > message from your system without making, distributing or 
> > > > retaining any copies
> > of it.
> > > > Although we believe that the message and any attachments are 
> > > > free from viruses and other errors that might affect the 
> > > > computer or it-system where it is received and read, the 
> > > > recipient opens the message at his or
> > > her own risk.
> > > > We assume no responsibility for any loss or damage arising from 
> > > > the receipt or use of this message.
> > > >
> >
>

Re: MLT and facetting

Posted by Zheng Lin Edwin Yeo <ed...@gmail.com>.
Hi Martin,

According to the JIRA, it says it is a bug, as it was working previously in
Solr 4. I have not tried Solr 4 before, so I'm not sure how it works.

For the ordering of the documents, do you mean to sort them according to
the criteria that you want?

Regards,
Edwin

On Wed, 27 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Thanks for your response. Are you sure it is a bug? Or is it not meant to
> work together?
> After doing some thinking I do see a problem faceting a MLT-result.
> MLT-results have a clear ordering of the documents which will be hard to
> maintain with facets. How will faceting MLT-results deal with the ordering
> of the documents? Will the ordering just be ignored?
>
> Best regards
>
> Martin
>
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 27. februar 2019 03:38
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> I also get the same problem in Solr 7.7 if I turn on faceting in /mlt
> requestHandler.
>
> Found this issue in the JIRA:
> https://issues.apache.org/jira/browse/SOLR-7883
> Seems like it is a bug in Solr and it has not been resolved yet.
>
> Regards,
> Edwin
>
> On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi Edwin,
> >
> > Here it is:
> >
> >
> > </requestHandler>
> >
> >
> > -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
> >
> >
> > -<lst name="defaults">
> >
> > <str name="mlt.fl">text</str>
> >
> > <str name="mlt.mintf">1</str>
> >
> > <str name="mlt.mindf">1</str>
> >
> > <str name="mlt.interestingTerms">true</str>
> >
> > </lst>
> >
> > </requestHandler>
> >
> >
> > Internal - KMD A/S
> >
> > -----Original Message-----
> > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > Sent: 26. februar 2019 08:24
> > To: solr-user@lucene.apache.org
> > Subject: Re: MLT and facetting
> >
> > Hi Martin,
> >
> > What is your setting in your /mlt requestHandler in solrconfig.xml?
> >
> > Regards,
> > Edwin
> >
> > On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > wrote:
> >
> > > Hi Edwin,
> > >
> > > Thanks for your response.
> > >
> > > Yes you are right. It was simply the search parameters from Solr.
> > >
> > > The query looks like this:
> > >
> > > http://
> > > .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Jo
> > > ur
> > > nalnummer&q=id:*6512815*
> > >
> > > best regards,
> > >
> > > Martin
> > >
> > >
> > > Internal - KMD A/S
> > >
> > > -----Original Message-----
> > > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > > Sent: 26. februar 2019 03:54
> > > To: solr-user@lucene.apache.org
> > > Subject: Re: MLT and facetting
> > >
> > > Hi Martin,
> > >
> > > I think there are some pictures which are not being sent through in
> > > the email.
> > >
> > > Do send your query that you are using, and which version of Solr you
> > > are using?
> > >
> > > Regards,
> > > Edwin
> > >
> > > On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > > wrote:
> > >
> > > > Hi,
> > > >
> > > >
> > > >
> > > > I am trying to combine the mlt functionality with facets, but Solr
> > > > throws
> > > > org.apache.solr.common.SolrException: ":"Unable to compute facet
> > > > ranges, facet context is not set".
> > > >
> > > >
> > > >
> > > > What I am trying to do is quite simple, find similar documents
> > > > using mlt and group these using the facet parameter. When using
> > > > mlt and facets separately everything works fine, but not when
> > > > combining the
> > > functionality.
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > {
> > > >
> > > >   "responseHeader":{
> > > >
> > > >     "status":500,
> > > >
> > > >     "QTime":109},
> > > >
> > > >   "match":{"numFound":1,"start":0,"docs":[
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00759",
> > > >
> > > >         "id":"6512815"  },
> > > >
> > > >   "response":{"numFound":602234,"start":0,"docs":[
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00759",
> > > >
> > > >         "id":"6512816",
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00759",
> > > >
> > > >         "id":"6834653"
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00739",
> > > >
> > > >         "id":"6202373"
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00739",
> > > >
> > > >         "id":"6748105"
> > > >
> > > >
> > > >
> > > >       {
> > > >
> > > >         "Journalnummer":" 00803",
> > > >
> > > >         "id":"7402155"
> > > >
> > > >   },
> > > >
> > > >   "error":{
> > > >
> > > >     "metadata":[
> > > >
> > > >       "error-class","org.apache.solr.common.SolrException",
> > > >
> > > >       "root-error-class","org.apache.solr.common.SolrException"],
> > > >
> > > >     "msg":"Unable to compute facet ranges, facet context is not
> > > > set",
> > > >
> > > >     "trace":"org.apache.solr.common.SolrException: Unable to
> > > > compute facet ranges, facet context is not set\n\tat
> > > > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRang
> > > > eC ou nts(RangeFacetProcessor.java:66)\n\tat
> > > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Fa
> > > > ce
> > > > tC
> > > > omponent.java:331)\n\tat
> > > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Fa
> > > > ce
> > > > tC
> > > > omponent.java:295)\n\tat
> > > > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(More
> > > > Li
> > > > ke
> > > > ThisHandler.java:240)\n\tat
> > > > org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHa
> > > > nd
> > > > le
> > > > rBase.java:199)\n\tat
> > > > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > > > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709
> > > > )\
> > > > n\
> > > > tat
> > > > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n
> > > > \t
> > > > at
> > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFi
> > > > lt
> > > > er
> > > > .java:377)\n\tat
> > > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFi
> > > > lt
> > > > er
> > > > .java:323)\n\tat
> > > > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Serv
> > > > le
> > > > tH
> > > > andler.java:1634)\n\tat
> > > >
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > > > 533)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > ja
> > > > va:146)\n\tat
> > > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
> > > > ja
> > > > va
> > > > :548)\n\tat
> > > >
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > java:132)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHa
> > > > nd
> > > > le
> > > > r.java:257)\n\tat
> > > > org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHa
> > > > nd
> > > > le
> > > > r.java:1595)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHa
> > > > nd
> > > > le
> > > > r.java:255)\n\tat
> > > > org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHa
> > > > nd
> > > > le
> > > > r.java:1317)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHan
> > > > dl
> > > > er
> > > > .java:203)\n\tat
> > > > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.ja
> > > > va
> > > > :4
> > > > 73)\n\tat
> > > > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHan
> > > > dl
> > > > er
> > > > .java:1564)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHan
> > > > dl
> > > > er
> > > > .java:201)\n\tat
> > > > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHan
> > > > dl
> > > > er
> > > > .java:1219)\n\tat
> > > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > > ja
> > > > va:144)\n\tat
> > > > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(C
> > > > on
> > > > te
> > > > xtHandlerCollection.java:219)\n\tat
> > > > org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerC
> > > > ol
> > > > le
> > > > ction.java:126)\n\tat
> > > >
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > java:132)\n\tat
> > > > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHan
> > > > dl
> > > > er
> > > > .java:335)\n\tat
> > > >
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > > java:132)\n\tat
> > > > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > > > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\
> > > > n\
> > > > ta
> > > > t
> > > > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
> > > > ja
> > > > va
> > > > :260)\n\tat
> > > > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abs
> > > > tr
> > > > ac
> > > > tConnection.java:281)\n\tat
> > > > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\
> > > > n\
> > > > ta
> > > > t
> > > > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:11
> > > > 8)
> > > > \n
> > > > \tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatW
> > > > ha
> > > > tY
> > > > ouKill.java:333)\n\tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(Ea
> > > > tW
> > > > ha
> > > > tYouKill.java:310)\n\tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(E
> > > > at
> > > > Wh
> > > > atYouKill.java:168)\n\tat
> > > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatY
> > > > ou
> > > > Ki
> > > > ll.java:126)\n\tat
> > > > org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > > > ru n(ReservedThreadExecutor.java:366)\n\tat
> > > > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThread
> > > > Po
> > > > ol
> > > > .java:762)\n\tat
> > > >
> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > > > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> > > >
> > > >     "code":500}}
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > In the above example I would like to facet on Journalnummer, thus
> > > > grouping several documents based on Journalnummer.
> > > >
> > > >
> > > >
> > > > Hope someone can help me, and thanks in advance.
> > > >
> > > >
> > > >
> > > > Best regards
> > > >
> > > >
> > > >
> > > > Martin
> > > >
> > > > Beskyttelse af dine personlige oplysninger er vigtig for os. Her
> > > > finder du KMD’s Privatlivspolitik
> > > > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> > > behandler oplysninger om dig.
> > > >
> > > > Protection of your personal data is important to us. Here you can
> > > > read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy>
> > > > outlining how we process your personal data.
> > > >
> > > > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
> > information.
> > > > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig
> > > > venligst informere afsender om fejlen ved at bruge svarfunktionen.
> > > > Samtidig beder vi dig slette e-mailen i dit system uden at
> > > > videresende eller
> > > kopiere den.
> > > > Selvom e-mailen og ethvert vedhæftet bilag efter vores
> > > > overbevisning er fri for virus og andre fejl, som kan påvirke
> > > > computeren eller it-systemet, hvori den modtages og læses, åbnes
> > > > den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar
> > > > for tab og skade, som er opstået i forbindelse med at modtage og
> bruge e-mailen.
> > > >
> > > > Please note that this message may contain confidential information.
> > > > If you have received this message by mistake, please inform the
> > > > sender of the mistake by sending a reply, then delete the message
> > > > from your system without making, distributing or retaining any
> > > > copies
> > of it.
> > > > Although we believe that the message and any attachments are free
> > > > from viruses and other errors that might affect the computer or
> > > > it-system where it is received and read, the recipient opens the
> > > > message at his or
> > > her own risk.
> > > > We assume no responsibility for any loss or damage arising from
> > > > the receipt or use of this message.
> > > >
> >
>

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Edwin,

Thanks for your response. Are you sure it is a bug? Or is it not meant to work together? 
After doing some thinking I do see a problem faceting a MLT-result. MLT-results have a clear ordering of the documents which will be hard to maintain with facets. How will faceting MLT-results deal with the ordering of the documents? Will the ordering just be ignored?

Best regards

Martin 



Internal - KMD A/S

-----Original Message-----
From: Zheng Lin Edwin Yeo <ed...@gmail.com> 
Sent: 27. februar 2019 03:38
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Hi Martin,

I also get the same problem in Solr 7.7 if I turn on faceting in /mlt requestHandler.

Found this issue in the JIRA:
https://issues.apache.org/jira/browse/SOLR-7883
Seems like it is a bug in Solr and it has not been resolved yet.

Regards,
Edwin

On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Here it is:
>
>
> </requestHandler>
>
>
> -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
>
>
> -<lst name="defaults">
>
> <str name="mlt.fl">text</str>
>
> <str name="mlt.mintf">1</str>
>
> <str name="mlt.mindf">1</str>
>
> <str name="mlt.interestingTerms">true</str>
>
> </lst>
>
> </requestHandler>
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 26. februar 2019 08:24
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> What is your setting in your /mlt requestHandler in solrconfig.xml?
>
> Regards,
> Edwin
>
> On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi Edwin,
> >
> > Thanks for your response.
> >
> > Yes you are right. It was simply the search parameters from Solr.
> >
> > The query looks like this:
> >
> > http://
> > .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Jo
> > ur
> > nalnummer&q=id:*6512815*
> >
> > best regards,
> >
> > Martin
> >
> >
> > Internal - KMD A/S
> >
> > -----Original Message-----
> > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > Sent: 26. februar 2019 03:54
> > To: solr-user@lucene.apache.org
> > Subject: Re: MLT and facetting
> >
> > Hi Martin,
> >
> > I think there are some pictures which are not being sent through in 
> > the email.
> >
> > Do send your query that you are using, and which version of Solr you 
> > are using?
> >
> > Regards,
> > Edwin
> >
> > On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > wrote:
> >
> > > Hi,
> > >
> > >
> > >
> > > I am trying to combine the mlt functionality with facets, but Solr 
> > > throws
> > > org.apache.solr.common.SolrException: ":"Unable to compute facet 
> > > ranges, facet context is not set".
> > >
> > >
> > >
> > > What I am trying to do is quite simple, find similar documents 
> > > using mlt and group these using the facet parameter. When using 
> > > mlt and facets separately everything works fine, but not when 
> > > combining the
> > functionality.
> > >
> > >
> > >
> > >
> > >
> > > {
> > >
> > >   "responseHeader":{
> > >
> > >     "status":500,
> > >
> > >     "QTime":109},
> > >
> > >   "match":{"numFound":1,"start":0,"docs":[
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00759",
> > >
> > >         "id":"6512815"  },
> > >
> > >   "response":{"numFound":602234,"start":0,"docs":[
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00759",
> > >
> > >         "id":"6512816",
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00759",
> > >
> > >         "id":"6834653"
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00739",
> > >
> > >         "id":"6202373"
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00739",
> > >
> > >         "id":"6748105"
> > >
> > >
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00803",
> > >
> > >         "id":"7402155"
> > >
> > >   },
> > >
> > >   "error":{
> > >
> > >     "metadata":[
> > >
> > >       "error-class","org.apache.solr.common.SolrException",
> > >
> > >       "root-error-class","org.apache.solr.common.SolrException"],
> > >
> > >     "msg":"Unable to compute facet ranges, facet context is not 
> > > set",
> > >
> > >     "trace":"org.apache.solr.common.SolrException: Unable to 
> > > compute facet ranges, facet context is not set\n\tat 
> > > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRang
> > > eC ou nts(RangeFacetProcessor.java:66)\n\tat
> > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Fa
> > > ce
> > > tC
> > > omponent.java:331)\n\tat
> > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Fa
> > > ce
> > > tC
> > > omponent.java:295)\n\tat
> > > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(More
> > > Li
> > > ke
> > > ThisHandler.java:240)\n\tat
> > > org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHa
> > > nd
> > > le
> > > rBase.java:199)\n\tat
> > > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709
> > > )\
> > > n\
> > > tat
> > > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n
> > > \t
> > > at
> > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFi
> > > lt
> > > er
> > > .java:377)\n\tat
> > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFi
> > > lt
> > > er
> > > .java:323)\n\tat
> > > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Serv
> > > le
> > > tH
> > > andler.java:1634)\n\tat
> > > org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > > 533)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > ja
> > > va:146)\n\tat
> > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.
> > > ja
> > > va
> > > :548)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > java:132)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHa
> > > nd
> > > le
> > > r.java:257)\n\tat
> > > org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHa
> > > nd
> > > le
> > > r.java:1595)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHa
> > > nd
> > > le
> > > r.java:255)\n\tat
> > > org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHa
> > > nd
> > > le
> > > r.java:1317)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHan
> > > dl
> > > er
> > > .java:203)\n\tat
> > > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.ja
> > > va
> > > :4
> > > 73)\n\tat
> > > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHan
> > > dl
> > > er
> > > .java:1564)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHan
> > > dl
> > > er
> > > .java:201)\n\tat
> > > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHan
> > > dl
> > > er
> > > .java:1219)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > ja
> > > va:144)\n\tat
> > > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(C
> > > on
> > > te
> > > xtHandlerCollection.java:219)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerC
> > > ol
> > > le
> > > ction.java:126)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > java:132)\n\tat
> > > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHan
> > > dl
> > > er
> > > .java:335)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > java:132)\n\tat
> > > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\
> > > n\
> > > ta
> > > t
> > > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.
> > > ja
> > > va
> > > :260)\n\tat
> > > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abs
> > > tr
> > > ac
> > > tConnection.java:281)\n\tat
> > > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\
> > > n\
> > > ta
> > > t
> > > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:11
> > > 8)
> > > \n
> > > \tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatW
> > > ha
> > > tY
> > > ouKill.java:333)\n\tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(Ea
> > > tW
> > > ha
> > > tYouKill.java:310)\n\tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(E
> > > at
> > > Wh
> > > atYouKill.java:168)\n\tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatY
> > > ou
> > > Ki
> > > ll.java:126)\n\tat
> > > org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > > ru n(ReservedThreadExecutor.java:366)\n\tat
> > > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThread
> > > Po
> > > ol
> > > .java:762)\n\tat
> > > org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> > >
> > >     "code":500}}
> > >
> > >
> > >
> > >
> > >
> > > In the above example I would like to facet on Journalnummer, thus 
> > > grouping several documents based on Journalnummer.
> > >
> > >
> > >
> > > Hope someone can help me, and thanks in advance.
> > >
> > >
> > >
> > > Best regards
> > >
> > >
> > >
> > > Martin
> > >
> > > Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
> > > finder du KMD’s Privatlivspolitik 
> > > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> > behandler oplysninger om dig.
> > >
> > > Protection of your personal data is important to us. Here you can 
> > > read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy>
> > > outlining how we process your personal data.
> > >
> > > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
> information.
> > > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig 
> > > venligst informere afsender om fejlen ved at bruge svarfunktionen. 
> > > Samtidig beder vi dig slette e-mailen i dit system uden at 
> > > videresende eller
> > kopiere den.
> > > Selvom e-mailen og ethvert vedhæftet bilag efter vores 
> > > overbevisning er fri for virus og andre fejl, som kan påvirke 
> > > computeren eller it-systemet, hvori den modtages og læses, åbnes 
> > > den på modtagerens eget ansvar. Vi påtager os ikke noget ansvar 
> > > for tab og skade, som er opstået i forbindelse med at modtage og bruge e-mailen.
> > >
> > > Please note that this message may contain confidential information.
> > > If you have received this message by mistake, please inform the 
> > > sender of the mistake by sending a reply, then delete the message 
> > > from your system without making, distributing or retaining any 
> > > copies
> of it.
> > > Although we believe that the message and any attachments are free 
> > > from viruses and other errors that might affect the computer or 
> > > it-system where it is received and read, the recipient opens the 
> > > message at his or
> > her own risk.
> > > We assume no responsibility for any loss or damage arising from 
> > > the receipt or use of this message.
> > >
>

Re: MLT and facetting

Posted by Zheng Lin Edwin Yeo <ed...@gmail.com>.
Hi Martin,

I also get the same problem in Solr 7.7 if I turn on faceting in /mlt
requestHandler.

Found this issue in the JIRA:
https://issues.apache.org/jira/browse/SOLR-7883
Seems like it is a bug in Solr and it has not been resolved yet.

Regards,
Edwin

On Tue, 26 Feb 2019 at 21:03, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Here it is:
>
>
> </requestHandler>
>
>
> -<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">
>
>
> -<lst name="defaults">
>
> <str name="mlt.fl">text</str>
>
> <str name="mlt.mintf">1</str>
>
> <str name="mlt.mindf">1</str>
>
> <str name="mlt.interestingTerms">true</str>
>
> </lst>
>
> </requestHandler>
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 26. februar 2019 08:24
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> What is your setting in your /mlt requestHandler in solrconfig.xml?
>
> Regards,
> Edwin
>
> On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi Edwin,
> >
> > Thanks for your response.
> >
> > Yes you are right. It was simply the search parameters from Solr.
> >
> > The query looks like this:
> >
> > http://
> > .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Jour
> > nalnummer&q=id:*6512815*
> >
> > best regards,
> >
> > Martin
> >
> >
> > Internal - KMD A/S
> >
> > -----Original Message-----
> > From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> > Sent: 26. februar 2019 03:54
> > To: solr-user@lucene.apache.org
> > Subject: Re: MLT and facetting
> >
> > Hi Martin,
> >
> > I think there are some pictures which are not being sent through in
> > the email.
> >
> > Do send your query that you are using, and which version of Solr you
> > are using?
> >
> > Regards,
> > Edwin
> >
> > On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> > wrote:
> >
> > > Hi,
> > >
> > >
> > >
> > > I am trying to combine the mlt functionality with facets, but Solr
> > > throws
> > > org.apache.solr.common.SolrException: ":"Unable to compute facet
> > > ranges, facet context is not set".
> > >
> > >
> > >
> > > What I am trying to do is quite simple, find similar documents using
> > > mlt and group these using the facet parameter. When using mlt and
> > > facets separately everything works fine, but not when combining the
> > functionality.
> > >
> > >
> > >
> > >
> > >
> > > {
> > >
> > >   "responseHeader":{
> > >
> > >     "status":500,
> > >
> > >     "QTime":109},
> > >
> > >   "match":{"numFound":1,"start":0,"docs":[
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00759",
> > >
> > >         "id":"6512815"  },
> > >
> > >   "response":{"numFound":602234,"start":0,"docs":[
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00759",
> > >
> > >         "id":"6512816",
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00759",
> > >
> > >         "id":"6834653"
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00739",
> > >
> > >         "id":"6202373"
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00739",
> > >
> > >         "id":"6748105"
> > >
> > >
> > >
> > >       {
> > >
> > >         "Journalnummer":" 00803",
> > >
> > >         "id":"7402155"
> > >
> > >   },
> > >
> > >   "error":{
> > >
> > >     "metadata":[
> > >
> > >       "error-class","org.apache.solr.common.SolrException",
> > >
> > >       "root-error-class","org.apache.solr.common.SolrException"],
> > >
> > >     "msg":"Unable to compute facet ranges, facet context is not
> > > set",
> > >
> > >     "trace":"org.apache.solr.common.SolrException: Unable to compute
> > > facet ranges, facet context is not set\n\tat
> > > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeC
> > > ou nts(RangeFacetProcessor.java:66)\n\tat
> > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Face
> > > tC
> > > omponent.java:331)\n\tat
> > > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Face
> > > tC
> > > omponent.java:295)\n\tat
> > > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLi
> > > ke
> > > ThisHandler.java:240)\n\tat
> > > org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHand
> > > le
> > > rBase.java:199)\n\tat
> > > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\
> > > n\
> > > tat
> > > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\t
> > > at
> > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilt
> > > er
> > > .java:377)\n\tat
> > > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilt
> > > er
> > > .java:323)\n\tat
> > > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servle
> > > tH
> > > andler.java:1634)\n\tat
> > > org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > > 533)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > ja
> > > va:146)\n\tat
> > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.ja
> > > va
> > > :548)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > java:132)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHand
> > > le
> > > r.java:257)\n\tat
> > > org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHand
> > > le
> > > r.java:1595)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHand
> > > le
> > > r.java:255)\n\tat
> > > org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHand
> > > le
> > > r.java:1317)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandl
> > > er
> > > .java:203)\n\tat
> > > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java
> > > :4
> > > 73)\n\tat
> > > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandl
> > > er
> > > .java:1564)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandl
> > > er
> > > .java:201)\n\tat
> > > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandl
> > > er
> > > .java:1219)\n\tat
> > > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > > ja
> > > va:144)\n\tat
> > > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(Con
> > > te
> > > xtHandlerCollection.java:219)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCol
> > > le
> > > ction.java:126)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > java:132)\n\tat
> > > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandl
> > > er
> > > .java:335)\n\tat
> > > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > > java:132)\n\tat
> > > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\
> > > ta
> > > t
> > > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.ja
> > > va
> > > :260)\n\tat
> > > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstr
> > > ac
> > > tConnection.java:281)\n\tat
> > > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\
> > > ta
> > > t
> > > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
> > > \n
> > > \tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWha
> > > tY
> > > ouKill.java:333)\n\tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatW
> > > ha
> > > tYouKill.java:310)\n\tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(Eat
> > > Wh
> > > atYouKill.java:168)\n\tat
> > > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYou
> > > Ki
> > > ll.java:126)\n\tat
> > > org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > > ru n(ReservedThreadExecutor.java:366)\n\tat
> > > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPo
> > > ol
> > > .java:762)\n\tat
> > > org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> > >
> > >     "code":500}}
> > >
> > >
> > >
> > >
> > >
> > > In the above example I would like to facet on Journalnummer, thus
> > > grouping several documents based on Journalnummer.
> > >
> > >
> > >
> > > Hope someone can help me, and thanks in advance.
> > >
> > >
> > >
> > > Best regards
> > >
> > >
> > >
> > > Martin
> > >
> > > Beskyttelse af dine personlige oplysninger er vigtig for os. Her
> > > finder du KMD’s Privatlivspolitik
> > > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> > behandler oplysninger om dig.
> > >
> > > Protection of your personal data is important to us. Here you can
> > > read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy>
> > > outlining how we process your personal data.
> > >
> > > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig
> information.
> > > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst
> > > informere afsender om fejlen ved at bruge svarfunktionen. Samtidig
> > > beder vi dig slette e-mailen i dit system uden at videresende eller
> > kopiere den.
> > > Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning
> > > er fri for virus og andre fejl, som kan påvirke computeren eller
> > > it-systemet, hvori den modtages og læses, åbnes den på modtagerens
> > > eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som
> > > er opstået i forbindelse med at modtage og bruge e-mailen.
> > >
> > > Please note that this message may contain confidential information.
> > > If you have received this message by mistake, please inform the
> > > sender of the mistake by sending a reply, then delete the message
> > > from your system without making, distributing or retaining any copies
> of it.
> > > Although we believe that the message and any attachments are free
> > > from viruses and other errors that might affect the computer or
> > > it-system where it is received and read, the recipient opens the
> > > message at his or
> > her own risk.
> > > We assume no responsibility for any loss or damage arising from the
> > > receipt or use of this message.
> > >
>

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Edwin,

Here it is: 


</requestHandler>


-<requestHandler class="solr.MoreLikeThisHandler" name="/mlt">


-<lst name="defaults">

<str name="mlt.fl">text</str>

<str name="mlt.mintf">1</str>

<str name="mlt.mindf">1</str>

<str name="mlt.interestingTerms">true</str>

</lst>

</requestHandler>


Internal - KMD A/S

-----Original Message-----
From: Zheng Lin Edwin Yeo <ed...@gmail.com> 
Sent: 26. februar 2019 08:24
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Hi Martin,

What is your setting in your /mlt requestHandler in solrconfig.xml?

Regards,
Edwin

On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Thanks for your response.
>
> Yes you are right. It was simply the search parameters from Solr.
>
> The query looks like this:
>
> http://
> .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Jour
> nalnummer&q=id:*6512815*
>
> best regards,
>
> Martin
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 26. februar 2019 03:54
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> I think there are some pictures which are not being sent through in 
> the email.
>
> Do send your query that you are using, and which version of Solr you 
> are using?
>
> Regards,
> Edwin
>
> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi,
> >
> >
> >
> > I am trying to combine the mlt functionality with facets, but Solr 
> > throws
> > org.apache.solr.common.SolrException: ":"Unable to compute facet 
> > ranges, facet context is not set".
> >
> >
> >
> > What I am trying to do is quite simple, find similar documents using 
> > mlt and group these using the facet parameter. When using mlt and 
> > facets separately everything works fine, but not when combining the
> functionality.
> >
> >
> >
> >
> >
> > {
> >
> >   "responseHeader":{
> >
> >     "status":500,
> >
> >     "QTime":109},
> >
> >   "match":{"numFound":1,"start":0,"docs":[
> >
> >       {
> >
> >         "Journalnummer":" 00759",
> >
> >         "id":"6512815"  },
> >
> >   "response":{"numFound":602234,"start":0,"docs":[
> >
> >       {
> >
> >         "Journalnummer":" 00759",
> >
> >         "id":"6512816",
> >
> >       {
> >
> >         "Journalnummer":" 00759",
> >
> >         "id":"6834653"
> >
> >       {
> >
> >         "Journalnummer":" 00739",
> >
> >         "id":"6202373"
> >
> >       {
> >
> >         "Journalnummer":" 00739",
> >
> >         "id":"6748105"
> >
> >
> >
> >       {
> >
> >         "Journalnummer":" 00803",
> >
> >         "id":"7402155"
> >
> >   },
> >
> >   "error":{
> >
> >     "metadata":[
> >
> >       "error-class","org.apache.solr.common.SolrException",
> >
> >       "root-error-class","org.apache.solr.common.SolrException"],
> >
> >     "msg":"Unable to compute facet ranges, facet context is not 
> > set",
> >
> >     "trace":"org.apache.solr.common.SolrException: Unable to compute 
> > facet ranges, facet context is not set\n\tat 
> > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeC
> > ou nts(RangeFacetProcessor.java:66)\n\tat
> > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Face
> > tC
> > omponent.java:331)\n\tat
> > org.apache.solr.handler.component.FacetComponent.getFacetCounts(Face
> > tC
> > omponent.java:295)\n\tat
> > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLi
> > ke
> > ThisHandler.java:240)\n\tat
> > org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHand
> > le
> > rBase.java:199)\n\tat
> > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\
> > n\
> > tat
> > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\t
> > at 
> > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilt
> > er
> > .java:377)\n\tat
> > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilt
> > er
> > .java:323)\n\tat
> > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servle
> > tH
> > andler.java:1634)\n\tat
> > org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > 533)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > ja
> > va:146)\n\tat
> > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.ja
> > va
> > :548)\n\tat
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > java:132)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHand
> > le
> > r.java:257)\n\tat
> > org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHand
> > le
> > r.java:1595)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHand
> > le
> > r.java:255)\n\tat
> > org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHand
> > le
> > r.java:1317)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandl
> > er
> > .java:203)\n\tat
> > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java
> > :4
> > 73)\n\tat
> > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandl
> > er
> > .java:1564)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandl
> > er
> > .java:201)\n\tat
> > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandl
> > er
> > .java:1219)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.
> > ja
> > va:144)\n\tat
> > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(Con
> > te
> > xtHandlerCollection.java:219)\n\tat
> > org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCol
> > le
> > ction.java:126)\n\tat
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > java:132)\n\tat
> > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandl
> > er
> > .java:335)\n\tat
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > java:132)\n\tat
> > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\
> > ta
> > t
> > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.ja
> > va
> > :260)\n\tat
> > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstr
> > ac
> > tConnection.java:281)\n\tat
> > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\
> > ta
> > t
> > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
> > \n
> > \tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWha
> > tY
> > ouKill.java:333)\n\tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatW
> > ha
> > tYouKill.java:310)\n\tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(Eat
> > Wh
> > atYouKill.java:168)\n\tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYou
> > Ki
> > ll.java:126)\n\tat
> > org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.
> > ru n(ReservedThreadExecutor.java:366)\n\tat
> > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPo
> > ol
> > .java:762)\n\tat
> > org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> >
> >     "code":500}}
> >
> >
> >
> >
> >
> > In the above example I would like to facet on Journalnummer, thus 
> > grouping several documents based on Journalnummer.
> >
> >
> >
> > Hope someone can help me, and thanks in advance.
> >
> >
> >
> > Best regards
> >
> >
> >
> > Martin
> >
> > Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
> > finder du KMD’s Privatlivspolitik 
> > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> behandler oplysninger om dig.
> >
> > Protection of your personal data is important to us. Here you can 
> > read KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy> 
> > outlining how we process your personal data.
> >
> > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
> > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst 
> > informere afsender om fejlen ved at bruge svarfunktionen. Samtidig 
> > beder vi dig slette e-mailen i dit system uden at videresende eller
> kopiere den.
> > Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning 
> > er fri for virus og andre fejl, som kan påvirke computeren eller 
> > it-systemet, hvori den modtages og læses, åbnes den på modtagerens 
> > eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som 
> > er opstået i forbindelse med at modtage og bruge e-mailen.
> >
> > Please note that this message may contain confidential information. 
> > If you have received this message by mistake, please inform the 
> > sender of the mistake by sending a reply, then delete the message 
> > from your system without making, distributing or retaining any copies of it.
> > Although we believe that the message and any attachments are free 
> > from viruses and other errors that might affect the computer or 
> > it-system where it is received and read, the recipient opens the 
> > message at his or
> her own risk.
> > We assume no responsibility for any loss or damage arising from the 
> > receipt or use of this message.
> >

Re: MLT and facetting

Posted by Zheng Lin Edwin Yeo <ed...@gmail.com>.
Hi Martin,

What is your setting in your /mlt requestHandler in solrconfig.xml?

Regards,
Edwin

On Tue, 26 Feb 2019 at 14:43, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi Edwin,
>
> Thanks for your response.
>
> Yes you are right. It was simply the search parameters from Solr.
>
> The query looks like this:
>
> http://
> .../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Journalnummer&q=id:*6512815*
>
> best regards,
>
> Martin
>
>
> Internal - KMD A/S
>
> -----Original Message-----
> From: Zheng Lin Edwin Yeo <ed...@gmail.com>
> Sent: 26. februar 2019 03:54
> To: solr-user@lucene.apache.org
> Subject: Re: MLT and facetting
>
> Hi Martin,
>
> I think there are some pictures which are not being sent through in the
> email.
>
> Do send your query that you are using, and which version of Solr you are
> using?
>
> Regards,
> Edwin
>
> On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk>
> wrote:
>
> > Hi,
> >
> >
> >
> > I am trying to combine the mlt functionality with facets, but Solr
> > throws
> > org.apache.solr.common.SolrException: ":"Unable to compute facet
> > ranges, facet context is not set".
> >
> >
> >
> > What I am trying to do is quite simple, find similar documents using
> > mlt and group these using the facet parameter. When using mlt and
> > facets separately everything works fine, but not when combining the
> functionality.
> >
> >
> >
> >
> >
> > {
> >
> >   "responseHeader":{
> >
> >     "status":500,
> >
> >     "QTime":109},
> >
> >   "match":{"numFound":1,"start":0,"docs":[
> >
> >       {
> >
> >         "Journalnummer":" 00759",
> >
> >         "id":"6512815"  },
> >
> >   "response":{"numFound":602234,"start":0,"docs":[
> >
> >       {
> >
> >         "Journalnummer":" 00759",
> >
> >         "id":"6512816",
> >
> >       {
> >
> >         "Journalnummer":" 00759",
> >
> >         "id":"6834653"
> >
> >       {
> >
> >         "Journalnummer":" 00739",
> >
> >         "id":"6202373"
> >
> >       {
> >
> >         "Journalnummer":" 00739",
> >
> >         "id":"6748105"
> >
> >
> >
> >       {
> >
> >         "Journalnummer":" 00803",
> >
> >         "id":"7402155"
> >
> >   },
> >
> >   "error":{
> >
> >     "metadata":[
> >
> >       "error-class","org.apache.solr.common.SolrException",
> >
> >       "root-error-class","org.apache.solr.common.SolrException"],
> >
> >     "msg":"Unable to compute facet ranges, facet context is not set",
> >
> >     "trace":"org.apache.solr.common.SolrException: Unable to compute
> > facet ranges, facet context is not set\n\tat
> > org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCou
> > nts(RangeFacetProcessor.java:66)\n\tat
> > org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetC
> > omponent.java:331)\n\tat
> > org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetC
> > omponent.java:295)\n\tat
> > org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLike
> > ThisHandler.java:240)\n\tat
> > org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandle
> > rBase.java:199)\n\tat
> > org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> > org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n\
> > tat
> > org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\tat
> > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter
> > .java:377)\n\tat
> > org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter
> > .java:323)\n\tat
> > org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletH
> > andler.java:1634)\n\tat
> > org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> > 533)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja
> > va:146)\n\tat
> > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java
> > :548)\n\tat
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > java:132)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandle
> > r.java:257)\n\tat
> > org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandle
> > r.java:1595)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandle
> > r.java:255)\n\tat
> > org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandle
> > r.java:1317)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler
> > .java:203)\n\tat
> > org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:4
> > 73)\n\tat
> > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler
> > .java:1564)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler
> > .java:201)\n\tat
> > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler
> > .java:1219)\n\tat
> > org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja
> > va:144)\n\tat
> > org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(Conte
> > xtHandlerCollection.java:219)\n\tat
> > org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerColle
> > ction.java:126)\n\tat
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > java:132)\n\tat
> > org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler
> > .java:335)\n\tat
> > org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> > java:132)\n\tat
> > org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> > org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\ta
> > t
> > org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java
> > :260)\n\tat
> > org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstrac
> > tConnection.java:281)\n\tat
> > org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\ta
> > t
> > org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\n
> > \tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatY
> > ouKill.java:333)\n\tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWha
> > tYouKill.java:310)\n\tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWh
> > atYouKill.java:168)\n\tat
> > org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKi
> > ll.java:126)\n\tat
> > org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.ru
> > n(ReservedThreadExecutor.java:366)\n\tat
> > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool
> > .java:762)\n\tat
> > org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> > java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
> >
> >     "code":500}}
> >
> >
> >
> >
> >
> > In the above example I would like to facet on Journalnummer, thus
> > grouping several documents based on Journalnummer.
> >
> >
> >
> > Hope someone can help me, and thanks in advance.
> >
> >
> >
> > Best regards
> >
> >
> >
> > Martin
> >
> > Beskyttelse af dine personlige oplysninger er vigtig for os. Her
> > finder du KMD’s Privatlivspolitik
> > <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi
> behandler oplysninger om dig.
> >
> > Protection of your personal data is important to us. Here you can read
> > KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy> outlining how
> > we process your personal data.
> >
> > Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
> > Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst
> > informere afsender om fejlen ved at bruge svarfunktionen. Samtidig
> > beder vi dig slette e-mailen i dit system uden at videresende eller
> kopiere den.
> > Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning
> > er fri for virus og andre fejl, som kan påvirke computeren eller
> > it-systemet, hvori den modtages og læses, åbnes den på modtagerens
> > eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som er
> > opstået i forbindelse med at modtage og bruge e-mailen.
> >
> > Please note that this message may contain confidential information. If
> > you have received this message by mistake, please inform the sender of
> > the mistake by sending a reply, then delete the message from your
> > system without making, distributing or retaining any copies of it.
> > Although we believe that the message and any attachments are free from
> > viruses and other errors that might affect the computer or it-system
> > where it is received and read, the recipient opens the message at his or
> her own risk.
> > We assume no responsibility for any loss or damage arising from the
> > receipt or use of this message.
> >

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Sorry forgot to mention that we are using Solr 7.5. 


Internal - KMD A/S

-----Original Message-----
From: Martin Frank Hansen (MHQ) <MH...@kmd.dk> 
Sent: 26. februar 2019 07:43
To: solr-user@lucene.apache.org
Subject: RE: MLT and facetting

Hi Edwin,

Thanks for your response. 

Yes you are right. It was simply the search parameters from Solr. 

The query looks like this:

http://.../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Journalnummer&q=id:*6512815*

best regards,

Martin


Internal - KMD A/S

-----Original Message-----
From: Zheng Lin Edwin Yeo <ed...@gmail.com>
Sent: 26. februar 2019 03:54
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Hi Martin,

I think there are some pictures which are not being sent through in the email.

Do send your query that you are using, and which version of Solr you are using?

Regards,
Edwin

On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi,
>
>
>
> I am trying to combine the mlt functionality with facets, but Solr 
> throws
> org.apache.solr.common.SolrException: ":"Unable to compute facet 
> ranges, facet context is not set".
>
>
>
> What I am trying to do is quite simple, find similar documents using 
> mlt and group these using the facet parameter. When using mlt and 
> facets separately everything works fine, but not when combining the functionality.
>
>
>
>
>
> {
>
>   "responseHeader":{
>
>     "status":500,
>
>     "QTime":109},
>
>   "match":{"numFound":1,"start":0,"docs":[
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6512815"  },
>
>   "response":{"numFound":602234,"start":0,"docs":[
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6512816",
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6834653"
>
>       {
>
>         "Journalnummer":" 00739",
>
>         "id":"6202373"
>
>       {
>
>         "Journalnummer":" 00739",
>
>         "id":"6748105"
>
>
>
>       {
>
>         "Journalnummer":" 00803",
>
>         "id":"7402155"
>
>   },
>
>   "error":{
>
>     "metadata":[
>
>       "error-class","org.apache.solr.common.SolrException",
>
>       "root-error-class","org.apache.solr.common.SolrException"],
>
>     "msg":"Unable to compute facet ranges, facet context is not set",
>
>     "trace":"org.apache.solr.common.SolrException: Unable to compute 
> facet ranges, facet context is not set\n\tat 
> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCou
> nts(RangeFacetProcessor.java:66)\n\tat
> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetC
> omponent.java:331)\n\tat
> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetC
> omponent.java:295)\n\tat
> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLike
> ThisHandler.java:240)\n\tat
> org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandle
> rBase.java:199)\n\tat
> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n\
> tat
> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\tat
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter
> .java:377)\n\tat
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter
> .java:323)\n\tat
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletH
> andler.java:1634)\n\tat
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> 533)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja
> va:146)\n\tat
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java
> :548)\n\tat
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> java:132)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandle
> r.java:257)\n\tat
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandle
> r.java:1595)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandle
> r.java:255)\n\tat
> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandle
> r.java:1317)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler
> .java:203)\n\tat
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:4
> 73)\n\tat
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler
> .java:1564)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler
> .java:201)\n\tat
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler
> .java:1219)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja
> va:144)\n\tat
> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(Conte
> xtHandlerCollection.java:219)\n\tat
> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerColle
> ction.java:126)\n\tat
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> java:132)\n\tat
> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler
> .java:335)\n\tat
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> java:132)\n\tat
> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\ta
> t
> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java
> :260)\n\tat
> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstrac
> tConnection.java:281)\n\tat
> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\ta
> t
> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\n
> \tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatY
> ouKill.java:333)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWha
> tYouKill.java:310)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWh
> atYouKill.java:168)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKi
> ll.java:126)\n\tat
> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.ru
> n(ReservedThreadExecutor.java:366)\n\tat
> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool
> .java:762)\n\tat
> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>
>     "code":500}}
>
>
>
>
>
> In the above example I would like to facet on Journalnummer, thus 
> grouping several documents based on Journalnummer.
>
>
>
> Hope someone can help me, and thanks in advance.
>
>
>
> Best regards
>
>
>
> Martin
>
> Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
> finder du KMD’s Privatlivspolitik 
> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi behandler oplysninger om dig.
>
> Protection of your personal data is important to us. Here you can read 
> KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy> outlining how 
> we process your personal data.
>
> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst 
> informere afsender om fejlen ved at bruge svarfunktionen. Samtidig 
> beder vi dig slette e-mailen i dit system uden at videresende eller kopiere den.
> Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning 
> er fri for virus og andre fejl, som kan påvirke computeren eller 
> it-systemet, hvori den modtages og læses, åbnes den på modtagerens 
> eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som er 
> opstået i forbindelse med at modtage og bruge e-mailen.
>
> Please note that this message may contain confidential information. If 
> you have received this message by mistake, please inform the sender of 
> the mistake by sending a reply, then delete the message from your 
> system without making, distributing or retaining any copies of it.
> Although we believe that the message and any attachments are free from 
> viruses and other errors that might affect the computer or it-system 
> where it is received and read, the recipient opens the message at his or her own risk.
> We assume no responsibility for any loss or damage arising from the 
> receipt or use of this message.
>

RE: MLT and facetting

Posted by "Martin Frank Hansen (MHQ)" <MH...@kmd.dk>.
Hi Edwin,

Thanks for your response. 

Yes you are right. It was simply the search parameters from Solr. 

The query looks like this:

http://.../solr/.../mlt?df=text&facet.field=Journalnummer&facet=on&fl=id,Journalnummer&q=id:*6512815*

best regards,

Martin


Internal - KMD A/S

-----Original Message-----
From: Zheng Lin Edwin Yeo <ed...@gmail.com> 
Sent: 26. februar 2019 03:54
To: solr-user@lucene.apache.org
Subject: Re: MLT and facetting

Hi Martin,

I think there are some pictures which are not being sent through in the email.

Do send your query that you are using, and which version of Solr you are using?

Regards,
Edwin

On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi,
>
>
>
> I am trying to combine the mlt functionality with facets, but Solr 
> throws
> org.apache.solr.common.SolrException: ":"Unable to compute facet 
> ranges, facet context is not set".
>
>
>
> What I am trying to do is quite simple, find similar documents using 
> mlt and group these using the facet parameter. When using mlt and 
> facets separately everything works fine, but not when combining the functionality.
>
>
>
>
>
> {
>
>   "responseHeader":{
>
>     "status":500,
>
>     "QTime":109},
>
>   "match":{"numFound":1,"start":0,"docs":[
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6512815"  },
>
>   "response":{"numFound":602234,"start":0,"docs":[
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6512816",
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6834653"
>
>       {
>
>         "Journalnummer":" 00739",
>
>         "id":"6202373"
>
>       {
>
>         "Journalnummer":" 00739",
>
>         "id":"6748105"
>
>
>
>       {
>
>         "Journalnummer":" 00803",
>
>         "id":"7402155"
>
>   },
>
>   "error":{
>
>     "metadata":[
>
>       "error-class","org.apache.solr.common.SolrException",
>
>       "root-error-class","org.apache.solr.common.SolrException"],
>
>     "msg":"Unable to compute facet ranges, facet context is not set",
>
>     "trace":"org.apache.solr.common.SolrException: Unable to compute 
> facet ranges, facet context is not set\n\tat 
> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCou
> nts(RangeFacetProcessor.java:66)\n\tat
> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetC
> omponent.java:331)\n\tat 
> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetC
> omponent.java:295)\n\tat 
> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLike
> ThisHandler.java:240)\n\tat 
> org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandle
> rBase.java:199)\n\tat 
> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n\
> tat 
> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\tat
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter
> .java:377)\n\tat 
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter
> .java:323)\n\tat 
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletH
> andler.java:1634)\n\tat 
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:
> 533)\n\tat 
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja
> va:146)\n\tat 
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java
> :548)\n\tat 
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> java:132)\n\tat 
> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandle
> r.java:257)\n\tat 
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandle
> r.java:1595)\n\tat 
> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandle
> r.java:255)\n\tat 
> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandle
> r.java:1317)\n\tat 
> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler
> .java:203)\n\tat 
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:4
> 73)\n\tat 
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler
> .java:1564)\n\tat 
> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler
> .java:201)\n\tat 
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler
> .java:1219)\n\tat 
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja
> va:144)\n\tat 
> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(Conte
> xtHandlerCollection.java:219)\n\tat
> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerColle
> ction.java:126)\n\tat 
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> java:132)\n\tat 
> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler
> .java:335)\n\tat 
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.
> java:132)\n\tat 
> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\ta
> t 
> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java
> :260)\n\tat 
> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstrac
> tConnection.java:281)\n\tat 
> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\ta
> t 
> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\n
> \tat 
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatY
> ouKill.java:333)\n\tat 
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWha
> tYouKill.java:310)\n\tat 
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWh
> atYouKill.java:168)\n\tat 
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKi
> ll.java:126)\n\tat 
> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.ru
> n(ReservedThreadExecutor.java:366)\n\tat
> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool
> .java:762)\n\tat 
> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.
> java:680)\n\tat java.lang.Thread.run(Thread.java:748)\n",
>
>     "code":500}}
>
>
>
>
>
> In the above example I would like to facet on Journalnummer, thus 
> grouping several documents based on Journalnummer.
>
>
>
> Hope someone can help me, and thanks in advance.
>
>
>
> Best regards
>
>
>
> Martin
>
> Beskyttelse af dine personlige oplysninger er vigtig for os. Her 
> finder du KMD’s Privatlivspolitik 
> <http://www.kmd.dk/Privatlivspolitik>, der fortæller, hvordan vi behandler oplysninger om dig.
>
> Protection of your personal data is important to us. Here you can read 
> KMD’s Privacy Policy <http://www.kmd.net/Privacy-Policy> outlining how 
> we process your personal data.
>
> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst 
> informere afsender om fejlen ved at bruge svarfunktionen. Samtidig 
> beder vi dig slette e-mailen i dit system uden at videresende eller kopiere den.
> Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning 
> er fri for virus og andre fejl, som kan påvirke computeren eller 
> it-systemet, hvori den modtages og læses, åbnes den på modtagerens 
> eget ansvar. Vi påtager os ikke noget ansvar for tab og skade, som er 
> opstået i forbindelse med at modtage og bruge e-mailen.
>
> Please note that this message may contain confidential information. If 
> you have received this message by mistake, please inform the sender of 
> the mistake by sending a reply, then delete the message from your 
> system without making, distributing or retaining any copies of it. 
> Although we believe that the message and any attachments are free from 
> viruses and other errors that might affect the computer or it-system 
> where it is received and read, the recipient opens the message at his or her own risk.
> We assume no responsibility for any loss or damage arising from the 
> receipt or use of this message.
>

Re: MLT and facetting

Posted by Zheng Lin Edwin Yeo <ed...@gmail.com>.
Hi Martin,

I think there are some pictures which are not being sent through in the
email.

Do send your query that you are using, and which version of Solr you are
using?

Regards,
Edwin

On Mon, 25 Feb 2019 at 20:54, Martin Frank Hansen (MHQ) <MH...@kmd.dk> wrote:

> Hi,
>
>
>
> I am trying to combine the mlt functionality with facets, but Solr throws
> org.apache.solr.common.SolrException: ":"Unable to compute facet ranges,
> facet context is not set".
>
>
>
> What I am trying to do is quite simple, find similar documents using mlt
> and group these using the facet parameter. When using mlt and facets
> separately everything works fine, but not when combining the functionality.
>
>
>
>
>
> {
>
>   "responseHeader":{
>
>     "status":500,
>
>     "QTime":109},
>
>   "match":{"numFound":1,"start":0,"docs":[
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6512815"  },
>
>   "response":{"numFound":602234,"start":0,"docs":[
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6512816",
>
>       {
>
>         "Journalnummer":" 00759",
>
>         "id":"6834653"
>
>       {
>
>         "Journalnummer":" 00739",
>
>         "id":"6202373"
>
>       {
>
>         "Journalnummer":" 00739",
>
>         "id":"6748105"
>
>
>
>       {
>
>         "Journalnummer":" 00803",
>
>         "id":"7402155"
>
>   },
>
>   "error":{
>
>     "metadata":[
>
>       "error-class","org.apache.solr.common.SolrException",
>
>       "root-error-class","org.apache.solr.common.SolrException"],
>
>     "msg":"Unable to compute facet ranges, facet context is not set",
>
>     "trace":"org.apache.solr.common.SolrException: Unable to compute facet
> ranges, facet context is not set\n\tat
> org.apache.solr.handler.component.RangeFacetProcessor.getFacetRangeCounts(RangeFacetProcessor.java:66)\n\tat
> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetComponent.java:331)\n\tat
> org.apache.solr.handler.component.FacetComponent.getFacetCounts(FacetComponent.java:295)\n\tat
> org.apache.solr.handler.MoreLikeThisHandler.handleRequestBody(MoreLikeThisHandler.java:240)\n\tat
> org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:199)\n\tat
> org.apache.solr.core.SolrCore.execute(SolrCore.java:2541)\n\tat
> org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:709)\n\tat
> org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:515)\n\tat
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:377)\n\tat
> org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:323)\n\tat
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1634)\n\tat
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:533)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:146)\n\tat
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548)\n\tat
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:257)\n\tat
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1595)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255)\n\tat
> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1317)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:203)\n\tat
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:473)\n\tat
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1564)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:201)\n\tat
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1219)\n\tat
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:144)\n\tat
> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:219)\n\tat
> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:126)\n\tat
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat
> org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:335)\n\tat
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)\n\tat
> org.eclipse.jetty.server.Server.handle(Server.java:531)\n\tat
> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:352)\n\tat
> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:260)\n\tat
> org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)\n\tat
> org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)\n\tat
> org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)\n\tat
> org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)\n\tat
> org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)\n\tat
> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:762)\n\tat
> org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:680)\n\tat
> java.lang.Thread.run(Thread.java:748)\n",
>
>     "code":500}}
>
>
>
>
>
> In the above example I would like to facet on Journalnummer, thus grouping
> several documents based on Journalnummer.
>
>
>
> Hope someone can help me, and thanks in advance.
>
>
>
> Best regards
>
>
>
> Martin
>
> Beskyttelse af dine personlige oplysninger er vigtig for os. Her finder du KMD’s
> Privatlivspolitik <http://www.kmd.dk/Privatlivspolitik>, der fortæller,
> hvordan vi behandler oplysninger om dig.
>
> Protection of your personal data is important to us. Here you can read KMD’s
> Privacy Policy <http://www.kmd.net/Privacy-Policy> outlining how we
> process your personal data.
>
> Vi gør opmærksom på, at denne e-mail kan indeholde fortrolig information.
> Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst
> informere afsender om fejlen ved at bruge svarfunktionen. Samtidig beder vi
> dig slette e-mailen i dit system uden at videresende eller kopiere den.
> Selvom e-mailen og ethvert vedhæftet bilag efter vores overbevisning er fri
> for virus og andre fejl, som kan påvirke computeren eller it-systemet,
> hvori den modtages og læses, åbnes den på modtagerens eget ansvar. Vi
> påtager os ikke noget ansvar for tab og skade, som er opstået i forbindelse
> med at modtage og bruge e-mailen.
>
> Please note that this message may contain confidential information. If you
> have received this message by mistake, please inform the sender of the
> mistake by sending a reply, then delete the message from your system
> without making, distributing or retaining any copies of it. Although we
> believe that the message and any attachments are free from viruses and
> other errors that might affect the computer or it-system where it is
> received and read, the recipient opens the message at his or her own risk.
> We assume no responsibility for any loss or damage arising from the receipt
> or use of this message.
>