Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-5629

SolrIndexSearcher.name should include core name

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 4.7, 6.0
    • None
    • None

    Description

      The name attribute on SolrIndexSearcher is used in log lines, but does not include the core name.

      So in a multi-core setup it is unnecessarily difficult to trace what core's searcher is being referred to, e.g. in log lines that provide info on searcher opens & closes.

      One-line patch that helps:

      Replace

      this.name = "Searcher@" + Integer.toHexString(hashCode()) + (name!=null ? " "+name : "");
      

      with

      this.name = "Searcher@" + Integer.toHexString(hashCode()) + "[" + core.getName() + "]" + (name!=null ? " "+name : "");
      

      Attachments

        Activity

          People

            erickerickson Erick Erickson
            shikhar Shikhar Bhushan
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: