Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-10133

streaming large content cause out of memory exception.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: Trunk
    • Fix Version/s: 17.12.01, 16.11.05
    • Component/s: content
    • Labels:
      None

      Description

      When ofbiz streams a large content (eg. video file), get out of memory exception.

      console output...
      2018-01-01 05:01:03,933 |jsse-nio-8443-exec-2 |MycoReqMapHandlerBase |E| Java heap space
      java.lang.OutOfMemoryError: Java heap space
      at org.apache.commons.io.output.ByteArrayOutputStream.needNewBuffer(ByteArrayOutputStream.java:127) ~[commons-io-2.5.jar:2.5]
      at org.apache.commons.io.output.ByteArrayOutputStream.write(ByteArrayOutputStream.java:158) ~[commons-io-2.5.jar:2.5]
      at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:2147) ~[commons-io-2.5.jar:2.5]
      at org.apache.commons.io.IOUtils.copy(IOUtils.java:2102) ~[commons-io-2.5.jar:2.5]
      at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:2123) ~[commons-io-2.5.jar:2.5]
      at org.apache.commons.io.IOUtils.copy(IOUtils.java:2078) ~[commons-io-2.5.jar:2.5]
      at org.apache.commons.io.IOUtils.toByteArray(IOUtils.java:721) ~[commons-io-2.5.jar:2.5]

        Attachments

        1. OFBIZ-10133.patch
          5 kB
          Wai
        2. OFBIZ-10133.patch
          15 kB
          Wai
        3. OFBIZ-10133.patch
          5 kB
          Wai
        4. OFBIZ-10133.patch
          5 kB
          Wai
        5. OFBIZ-10133.patch
          5 kB
          Wai
        6. OFBIZ-10133.patch
          4 kB
          Wai
        7. OFBIZ-10133.patch
          3 kB
          Wai
        8. OFBIZ-10133.patch
          2 kB
          Wai

          Issue Links

            Activity

              People

              • Assignee:
                jacques.le.roux Jacques Le Roux
                Reporter:
                wt Wai
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: