Skip to content

Commit 3cb3ab7

Browse files
committed
updateBlob! is obsolete
1 parent 8bd2e9f commit 3cb3ab7

3 files changed

Lines changed: 6 additions & 21 deletions

File tree

src/DataBlobs/services/BlobStores.jl

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -76,14 +76,6 @@ end
7676
# also creates an blobid as uuid4
7777
addBlob!(store::AbstractBlobstore, data) = addBlob!(store, uuid4(), data)
7878

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
8779
#delete
8880
function deleteBlob!(dfg::AbstractDFG, entry::Blobentry)
8981
return deleteBlob!(getBlobstore(dfg, entry.blobstore), entry)
@@ -171,10 +163,6 @@ function addBlob!(store::FolderStore{T}, blobid::UUID, data::T) where {T}
171163
end
172164
end
173165

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-
178166
function deleteBlob!(store::FolderStore{T}, blobid::UUID) where {T}
179167
# Tombstone pattern: instead of deleting the file, create a tombstone marker file
180168
blobfilename = joinpath(store.folder, string(store.label), string(blobid))
@@ -243,13 +231,6 @@ function addBlob!(store::InMemoryBlobstore{T}, blobid::UUID, data::T) where {T}
243231
return blobid
244232
end
245233

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-
253234
function deleteBlob!(store::InMemoryBlobstore, blobid::UUID)
254235
if !haskey(store.blobs, blobid)
255236
throw(IdNotFoundError("Blob", blobid))

src/Deprecated.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -344,6 +344,10 @@ function getFactorState(args...)
344344
)
345345
end
346346

347+
function updateBlob!(args...)
348+
return error("updateBlob! is obsolete as blobid=>Blob pairs are immutable.")
349+
end
350+
347351
## ================================================================================
348352
## Deprecated in v0.28
349353
##=================================================================================

src/DistributedFactorGraphs.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -427,8 +427,6 @@ const unstable_functions::Vector{Symbol} = [
427427
:mergeGraph!,
428428
:buildSubgraph,
429429
:incrDataLabelSuffix,# TODO somewhat used, do we deprecate?
430-
:updateMetadata!,## TODO deprecated or obsolete
431-
:updateBlob!,## TODO deprecated or obsolete
432430

433431
# set # TODO what to do here, maybe `ref` verb + setproperty.
434432
:setSolverParams!,
@@ -440,6 +438,8 @@ const unstable_functions::Vector{Symbol} = [
440438
# no set on these
441439

442440
#deprecated in v0.29
441+
:updateMetadata!,## TODO deprecated or obsolete
442+
:updateBlob!,## TODO deprecated or obsolete
443443
:getFactorState, # FIXME getFactorState were questioned and being reviewed again for name, other than that they are checked.
444444
:packDistribution,
445445
:unpackDistribution,

0 commit comments

Comments
 (0)