/AWS1/IF_S3=>DELETEOBJECTANNOTATION()¶
About DeleteObjectAnnotation¶
Deletes a specific annotation from an Amazon S3 object. Use the x-amz-object-if-match
header to perform a conditional delete that only succeeds if the object's ETag matches the
provided value, preventing race conditions during concurrent updates.
Deleting an annotation is permanent. Annotations are not independently versioned, so there is no delete marker or way to recover a deleted annotation.
To use this operation, you must have the s3:DeleteObjectAnnotation permission. If
the object is protected by Object Lock in governance mode, you must also include the
x-amz-bypass-governance-retention header.
Annotations are not supported by the following features: S3 Inventory Reports, API Gateway, S3 Storage Lens, Amazon S3 File Gateway, Amazon FSx, S3 on Outposts, and S3 Express One Zone (directory buckets).
The following operations are related to DeleteObjectAnnotation:
Method Signature¶
METHODS /AWS1/IF_S3~DELETEOBJECTANNOTATION
IMPORTING
!IV_BUCKET TYPE /AWS1/S3_BUCKETNAME OPTIONAL
!IV_KEY TYPE /AWS1/S3_OBJECTKEY OPTIONAL
!IV_ANNOTATIONNAME TYPE /AWS1/S3_ANNOTATIONNAME OPTIONAL
!IV_VERSIONID TYPE /AWS1/S3_OBJECTVERSIONID OPTIONAL
!IV_REQUESTPAYER TYPE /AWS1/S3_REQUESTPAYER OPTIONAL
!IV_EXPECTEDBUCKETOWNER TYPE /AWS1/S3_ACCOUNTID OPTIONAL
!IV_OBJECTIFMATCH TYPE /AWS1/S3_OBJECTIFMATCH OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_s3_delobjannotoutput
RAISING
/AWS1/CX_S3_NOSUCHBUCKET
/AWS1/CX_S3_NOSUCHKEY
/AWS1/CX_S3_CLIENTEXC
/AWS1/CX_S3_SERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_bucket TYPE /AWS1/S3_BUCKETNAME /AWS1/S3_BUCKETNAME¶
The name of the bucket that contains the object.
iv_key TYPE /AWS1/S3_OBJECTKEY /AWS1/S3_OBJECTKEY¶
The object key.
iv_annotationname TYPE /AWS1/S3_ANNOTATIONNAME /AWS1/S3_ANNOTATIONNAME¶
The name of the annotation to delete. Annotation names are UTF-8 encoded and cannot start with
awsors3(case-insensitive).Length Constraints: Minimum length of 1. Maximum length of 512 bytes.
Optional arguments:¶
iv_versionid TYPE /AWS1/S3_OBJECTVERSIONID /AWS1/S3_OBJECTVERSIONID¶
The version ID of the object.
iv_requestpayer TYPE /AWS1/S3_REQUESTPAYER /AWS1/S3_REQUESTPAYER¶
Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for the corresponding charges. For information about downloading objects from Requester Pays buckets, see Downloading Objects in Requester Pays Buckets in the Amazon S3 User Guide.
This functionality is not supported for directory buckets.
iv_expectedbucketowner TYPE /AWS1/S3_ACCOUNTID /AWS1/S3_ACCOUNTID¶
The account ID of the expected bucket owner.
iv_objectifmatch TYPE /AWS1/S3_OBJECTIFMATCH /AWS1/S3_OBJECTIFMATCH¶
If specified, the operation only succeeds if the object's ETag matches the provided value.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_s3_delobjannotoutput /AWS1/CL_S3_DELOBJANNOTOUTPUT¶
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->deleteobjectannotation(
iv_annotationname = |string|
iv_bucket = |string|
iv_expectedbucketowner = |string|
iv_key = |string|
iv_objectifmatch = |string|
iv_requestpayer = |string|
iv_versionid = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_objectversionid = lo_result->get_objectversionid( ).
lv_requestcharged = lo_result->get_requestcharged( ).
ENDIF.