MCPcopy Create free account
hub / github.com/apache/cloudberry / putResponseWithRetries

Method putResponseWithRetries

gpcontrib/gpcloud/src/s3interface.cpp:61–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59};
60
61Response S3InterfaceService::putResponseWithRetries(const string &url, HTTPHeaders &headers,
62 S3VectorUInt8 &data, uint64_t retries) {
63 string message;
64 uint64_t retry = retries;
65
66 while (retry--) {
67 try {
68 return this->restfulService->put(url, headers, data);
69 } catch (S3ConnectionError &e) {
70 message = e.getMessage();
71 if (S3QueryIsAbortInProgress()) {
72 S3_DIE(S3QueryAbort, "Uploading is interrupted");
73 }
74 S3WARN("Failed to get a good response in PUT from '%s', retrying ...", url.c_str());
75 }
76 };
77
78 S3_DIE(S3FailedAfterRetry, url, retries, message);
79};
80
81Response S3InterfaceService::postResponseWithRetries(const string &url, HTTPHeaders &headers,
82 const vector<uint8_t> &data,

Callers 2

uploadPartOfDataMethod · 0.95
TEST_FFunction · 0.80

Calls 3

S3QueryIsAbortInProgressFunction · 0.70
putMethod · 0.45
getMessageMethod · 0.45

Tested by 1

TEST_FFunction · 0.64