You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Jukka Zitting (JIRA)" <ji...@apache.org> on 2013/11/09 21:44:17 UTC
[jira] [Created] (OAK-1164) Duplicate binaries
Jukka Zitting created OAK-1164:
----------------------------------
Summary: Duplicate binaries
Key: OAK-1164
URL: https://issues.apache.org/jira/browse/OAK-1164
Project: Jackrabbit Oak
Issue Type: Bug
Components: core
Reporter: Jukka Zitting
Assignee: Jukka Zitting
The following piece of code currently causes a binary to be stored (or at least read) twice:
{code}
InputStream stream = ...;
Session session = ...;
Value value = sesion.getValueFactory().createValue(stream);
session.getRootNode().setProperty("data", value);
node.save();
{code}
The reason is the {{ValueBasedBlob}} class that prevents the underlying storage to see that the {{Blob}} being saved was already stored earlier and thus no extra copy is needed.
--
This message was sent by Atlassian JIRA
(v6.1#6144)