C#C
C#2y ago
NeRooN

Amazon S3 client total request count

Hello, i need some help in something i assume it's easy but i need to be 100% sure.

I have an s3client that i use to make some requests to amazon s3. Now i need to log the total GET/POST/PUT/DELETE requests i do. I assume it's only 1 request per call, but to be 100% sure i prefer to ask here how can i check this.

The idea is to have methods like:

    Public Function GetObjectMetadata(metadataRequest As GetObjectMetadataRequest) As GetObjectMetadataResponse
        GetRequests += 1
        Return S3Client.GetObjectMetadata(metadataRequest)
    End Function


so when i do the "GetObjectMetadata" request, it adds 1 to the counter. So i need to be sure every mehtod i call does only 1 request, in case it does some extra requests i should then add something like "PostRequest += 1" or smth like that
Was this page helpful?