db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kristian Waagan (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-3818) client Insert/retrieval of 18MB Clob is extremely slow in MultiByteClobTest
Date Tue, 05 Aug 2008 16:02:44 GMT

    [ https://issues.apache.org/jira/browse/DERBY-3818?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12619937#action_12619937
] 

Kristian Waagan commented on DERBY-3818:
----------------------------------------

Insert performance is acceptable.

The problem is the select. We fetch the Clob piece by piece. Again we're hit by the problem
I tried to solve with DERBY-3769.
The limit for what we can transfer in one go is not 32672 characters, it seems to be 32672
bytes. So Derby ends up advancing the stream too far, and has to reset the stream and skip
the data until correctly positioned again. Probably we obtain a substring of 32672 characters,
call String.getBytes(UTF8) and then selects the first 32672 bytes of the resulting byte array.
The rest is discarded.
Data is going over the line as UTF-8.

The next problem hit is the naive repositioning algorithm, which we cannot avoid by adjusting
the buffer size. This is the same issue as for Blob (DERBY-3766). I'll log a Jira for this,
and maybe upload a patch for review before I go on vacation.

I haven't spent a lot of time investigating this, but a simple experiment (with some other
unfinished code as well) brought the time on my machine down to 60 seconds, running both the
embedded and the client suite.

> client Insert/retrieval of 18MB  Clob is extremely slow  in MultiByteClobTest
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-3818
>                 URL: https://issues.apache.org/jira/browse/DERBY-3818
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC, Network Client
>    Affects Versions: 10.5.0.0
>            Reporter: Kathey Marsden
>
> In the test memory.MultiByteClobTest that was added for DERBY-3741, the client version
of the test took 525000ms vs 9578ms for embedded, so I disabled the client test for now. 
The client test should be analyzed to determine why Clob handling is so slow.   I am not sure
if the problem is on the insert, the retrieval or both.  Once this issue is resolved it would
be good to enable the test for client.  

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message