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

HashJoinStream's use of String::hashCode results in non-matching tuples being considered matches

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 6.0
    • Fix Version/s: 7.4
    • Component/s: SolrJ
    • Labels:
      None

      Description

      The following strings have been found to have hashCode conflicts and as such can result in HashJoinStream considering two tuples with fields of these values to be considered the same.

      "MG!!00TNGP::Mtge::".hashCode() == "MG!!00TNH1::Mtge::".hashCode() 

      This means these two tuples are the same if we're comparing on field "foo"

      {
        "foo":"MG!!00TNGP::Mtge::"
      }
      {
        "foo":"MG!!00TNH1::Mtge::"
      }
      

      and these two tuples are the same if we're comparing on fields "foo,bar"

      {
        "foo":"MG!!00TNGP"
        "bar":"Mtge"
      }
      {
        "foo":"MG!!00TNH1"
        "bar":"Mtge"
      }

        Attachments

          Activity

            People

            • Assignee:
              dpgove Dennis Gove
              Reporter:
              dpgove Dennis Gove

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment