Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4219374

RandomAccessFile is seriously slow

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P4 P4
    • None
    • 1.2.0
    • core-libs
    • generic
    • generic



      Name: vi73552 Date: 03/11/99


      I know this has been reported previously, but RandomAccessFile
      has some *serious* defeciencies that *must* be addressed in
      a future version of the JDK. As previously reported (4137835,
      4170047 seem relevant), read(Int|Long|Double|Float) and the
      corresponding write calls each make multiple (4 to 8) native
      and most likely kernel calls. What is even worse though is
      readUTF/writeUTF need to make 1026 native/kernel calls just to
      read/write a 1024 byte String!!! In order to get any reasonable
      performance everybody has to write their own silly wrapper
      class or subclass of RandomAccessFile. In addition,
      write/readUTF have an arbitrary maximum String length of 65535.
      Strings can be a bit longer...

      Don't ignore the problem and hope it will go away. Fix it.
      *PLEASE*. Make a *new* class the people can use and deprecate
      the old one. Do *something* other than ignoring the problem and
      closing the bug reports.
      (Review ID: 55370)
      ======================================================================

            Unassigned Unassigned
            vasya Vassili Igouchkine (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: