Uploaded image for project: 'Commons CSV'
  1. Commons CSV
  2. CSV-18

CharBuffer is too slow.

    XMLWordPrintableJSON

Details

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

    Description

      It's too slow reading large field(about 10000 over) because of org.apache.commons.csv.CharBuffer.
      Change provideCapacity method to below or copy-paste org.apache.commons.collections.primitives.ArrayCharList.

      public void provideCapacity(final int capacity)

      { if (c.length >= capacity) return; int newcapacity = capacity * 3 / 2 + 1; char[] newc = new char[newcapacity]; System.arraycopy(c, 0, newc, 0, length); c = newc; }

      Attachments

        Activity

          People

            Unassigned Unassigned
            miyabe MIYABE Tatsuhiko
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: