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 "Matt Ryan (Jira)" <ji...@apache.org> on 2019/08/28 23:32:00 UTC

[jira] [Resolved] (OAK-8298) [Direct Binary Access] Blobs that are directly uploaded are not tracked by BlobIdTracker

     [ https://issues.apache.org/jira/browse/OAK-8298?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Matt Ryan resolved OAK-8298.
----------------------------
    Resolution: Fixed

> [Direct Binary Access] Blobs that are directly uploaded are not tracked by BlobIdTracker
> ----------------------------------------------------------------------------------------
>
>                 Key: OAK-8298
>                 URL: https://issues.apache.org/jira/browse/OAK-8298
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>          Components: blob-cloud, blob-cloud-azure, blob-plugins
>    Affects Versions: 1.16.0, 1.10.4
>            Reporter: Matt Ryan
>            Assignee: Matt Ryan
>            Priority: Major
>             Fix For: 1.18.0, 1.10.5
>
>
> Blobs that are uploaded to the content repository are supposed to be tracked by the {{BlobIdTracker}} once the blob is saved.  This is done for blobs uploaded the traditional way in {{DataStoreBlobStore.writeBlob()}} [0].
> For blobs uploaded directly, they do not go through this method and so the blob ID is never added to the {{BlobIdTracker}}.  This has impact on DSGC as the {{MarkSweepGarbageCollector}} relies on the {{BlobIdTracker}} to provide an accurate accounting of the blob IDs in the blob store to determine which ones to retain and which to delete.
> This should be a pretty easy fix.  All direct uploads pass through {{DataStoreBlobStore.completeBlobUpload()}} [1], and we have at that point access to the {{DataRecord}} created by the direct upload.  We can get the blob ID from the {{DataRecord}} and add it to the {{BlobIdTracker}} there.
> [0] - [https://github.com/apache/jackrabbit-oak/blob/trunk/oak-blob-plugins/src/main/java/org/apache/jackrabbit/oak/plugins/blob/datastore/DataStoreBlobStore.java#L241]
> [1] - [https://github.com/apache/jackrabbit-oak/blob/46cde5ee49622c94bc95648edf84cf4c00ae1d58/oak-blob-plugins/src/main/java/org/apache/jackrabbit/oak/plugins/blob/datastore/DataStoreBlobStore.java#L723]



--
This message was sent by Atlassian Jira
(v8.3.2#803003)