MCPcopy Index your code
hub / github.com/NVIDIA/aistore / DeleteObject

Function DeleteObject

api/object.go:227–238  ·  view source on GitHub ↗

DeleteObject deletes an object specified by bucket/object.

(baseParams BaseParams, bck cmn.Bck, object string)

Source from the content-addressed store, hash-verified

225
226// DeleteObject deletes an object specified by bucket/object.
227func DeleteObject(baseParams BaseParams, bck cmn.Bck, object string) error {
228 baseParams.Method = http.MethodDelete
229 reqParams := AllocRp()
230 {
231 reqParams.BaseParams = baseParams
232 reqParams.Path = apc.URLPathObjects.Join(bck.Name, object)
233 reqParams.Query = bck.AddToQuery(nil)
234 }
235 err := reqParams.DoHTTPRequest()
236 FreeRp(reqParams)
237 return err
238}
239
240// EvictObject evicts an object specified by bucket/object.
241func EvictObject(baseParams BaseParams, bck cmn.Bck, object string) error {

Callers 15

DeleteObjectMethod · 0.92
multiObjOpFunction · 0.92
rmRfAllObjectsFunction · 0.92
DeleteObjMethod · 0.92
doMethod · 0.92
delMethod · 0.92
TestCopyObjRangeFunction · 0.92
testETLMultiObjFunction · 0.92
TestETLTar2TFS3Function · 0.92
opDeleteFunction · 0.92
TestAtimeColdGetFunction · 0.92
TestAtimePrefetchFunction · 0.92

Calls 5

AllocRpFunction · 0.85
FreeRpFunction · 0.85
JoinMethod · 0.80
DoHTTPRequestMethod · 0.80
AddToQueryMethod · 0.45

Tested by 11

doMethod · 0.74
TestCopyObjRangeFunction · 0.74
testETLMultiObjFunction · 0.74
TestETLTar2TFS3Function · 0.74
opDeleteFunction · 0.74
TestAtimeColdGetFunction · 0.74
TestAtimePrefetchFunction · 0.74
TestRemoteBucketObjectFunction · 0.74
testETLObjectCloudFunction · 0.74