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

NegativeArraySizeException on TransactionLog if previous document more than 1.9GB

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 7.4
    • None
    • None

    Description

      In TransactionLog, we have

      bufSize = Math.min(1024*1024, lastAddSize+(lastAddSize>>3)+256);
      
      MemOutputStream out = new MemOutputStream(new byte[bufSize]);
      

      Note that bufSize will be a negative number if lastAddSize > 1908874127 ( which is around 1.9GB).

      Although this seems to relate to user's error because of sending such a big document. But the exception is thrown for the update after the big one. Therefore it is better to fix the problem and solving how we can prohibit users from sending very big documents in other issues.

      Attachments

        1. SOLR-12250.patch
          3 kB
          Cao Manh Dat
        2. SOLR-12250.patch
          3 kB
          Cao Manh Dat

        Activity

          People

            caomanhdat Cao Manh Dat
            caomanhdat Cao Manh Dat
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: