[
https://issues.apache.org/jira/browse/DERBY-4686?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12879078#action_12879078
]
Knut Anders Hatlen commented on DERBY-4686:
-------------------------------------------
Would it make sense to replace this line
byte[] buffer = new byte[LEN_OF_BUFFER_TO_WRITE_BLOB];
with this
byte[] buffer = new byte[Math.min(len, LEN_OF_BUFFER_TO_WRITE_BLOB)];
so that we don't allocate a buffer that's larger than the value we're going to
read?
> SQLBinary.writeBlob is inefficient, reading one byte at a time from the
> source BLOB
> -----------------------------------------------------------------------------------
>
> Key: DERBY-4686
> URL: https://issues.apache.org/jira/browse/DERBY-4686
> Project: Derby
> Issue Type: Improvement
> Components: Store
> Affects Versions: 10.7.0.0
> Reporter: Kristian Waagan
> Assignee: Yun Lee
> Fix For: 10.7.0.0
>
> Attachments: DERBY-4686-1.diff, DERBY-4686-1.diff, DERBY-4686.diff
>
>
> SQLBinary.writeBlob is inefficient, since it is only reading one byte at the
> time from the source BLOB.
> It would be better if a transfer buffer was used to facilitate the write.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.