Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-3825

StoreStreamClob.getReader(charPos) performs poorly

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 10.5.1.1
    • 10.4.2.1, 10.5.1.1
    • JDBC, Store
    • None
    • Performance

    Description

      StoreStreamClob.getReader(charPos) performs poorly because it resets the underlying stream and skips data until it reached the requested character position. Not only does the data has to be skipped, it also has to be decoded (UTF-8).
      The problem is exposed through EmbedClob.getSubString, which causes extremely bad performance for the client driver because the locator based Clob implementation uses this method.

      For the record, there is another read buffer size issue that exaggerates the problem (it will probably be handled under DERBY-3769, and also DERBY-3818).

      Attachments

        1. derby-3825-0a-preview.diff
          10 kB
          Kristian Waagan
        2. derby-3825-1a-reset_readpositioninbuffer.diff
          2 kB
          Kristian Waagan
        3. derby-3825-2a-internalReader_repositioning.diff
          22 kB
          Kristian Waagan
        4. derby-3825-2a-internalReader_repositioning.stat
          0.4 kB
          Kristian Waagan
        5. derby-3825-2b-internalReader_repositioning.diff
          24 kB
          Kristian Waagan
        6. derby-3825-3a-simplification.diff
          2 kB
          Kristian Waagan

        Activity

          People

            kristwaa Kristian Waagan
            kristwaa Kristian Waagan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: