|
76 | 76 | # also creates an blobid as uuid4 |
77 | 77 | addBlob!(store::AbstractBlobstore, data) = addBlob!(store, uuid4(), data) |
78 | 78 |
|
79 | | -#update |
80 | | -function updateBlob!(dfg::AbstractDFG, entry::Blobentry, data) |
81 | | - return updateBlob!(getBlobstore(dfg, entry.blobstore), entry.blobid, data) |
82 | | -end |
83 | | - |
84 | | -function updateBlob!(store::AbstractBlobstore, entry::Blobentry, data) |
85 | | - return updateBlob!(store, entry.blobid, data) |
86 | | -end |
87 | 79 | #delete |
88 | 80 | function deleteBlob!(dfg::AbstractDFG, entry::Blobentry) |
89 | 81 | return deleteBlob!(getBlobstore(dfg, entry.blobstore), entry) |
@@ -171,10 +163,6 @@ function addBlob!(store::FolderStore{T}, blobid::UUID, data::T) where {T} |
171 | 163 | end |
172 | 164 | end |
173 | 165 |
|
174 | | -function updateBlob!(store::FolderStore{T}, blobid::UUID, data::T) where {T} |
175 | | - return error("updateBlob! is obsolete as blobid=>Blob pairs are immutable.") |
176 | | -end |
177 | | - |
178 | 166 | function deleteBlob!(store::FolderStore{T}, blobid::UUID) where {T} |
179 | 167 | # Tombstone pattern: instead of deleting the file, create a tombstone marker file |
180 | 168 | blobfilename = joinpath(store.folder, string(store.label), string(blobid)) |
@@ -243,13 +231,6 @@ function addBlob!(store::InMemoryBlobstore{T}, blobid::UUID, data::T) where {T} |
243 | 231 | return blobid |
244 | 232 | end |
245 | 233 |
|
246 | | -function updateBlob!(store::InMemoryBlobstore{T}, blobid::UUID, data::T) where {T} |
247 | | - if haskey(store.blobs, blobid) |
248 | | - @warn "Key '$blobid' doesn't exist." |
249 | | - end |
250 | | - return store.blobs[blobid] = data |
251 | | -end |
252 | | - |
253 | 234 | function deleteBlob!(store::InMemoryBlobstore, blobid::UUID) |
254 | 235 | if !haskey(store.blobs, blobid) |
255 | 236 | throw(IdNotFoundError("Blob", blobid)) |
|
0 commit comments