github-actions[bot] commented on code in PR #68967:
URL: https://github.com/apache/doris/pull/68967#discussion_r4254234543


##########
cloud/src/recycler/s3_accessor.cpp:
##########
@@ -325,15 +325,7 @@ std::string S3Accessor::to_uri(const std::string& 
relative_path) const {
 
 int S3Accessor::create(S3Conf conf, std::shared_ptr<S3Accessor>* accessor) {
     TEST_SYNC_POINT_RETURN_WITH_VALUE("S3Accessor::init.s3_init_failed", 
(int)-1);
-    switch (conf.provider) {
-    case S3Conf::GCS:
-        *accessor = std::make_shared<GcsAccessor>(conf);
-        break;
-    default:
-        *accessor = std::make_shared<S3Accessor>(conf);
-        break;
-    }
-
+    *accessor = std::make_shared<S3Accessor>(conf);

Review Comment:
   [P2] Preserve GCS cleanup when the bucket is already absent
   
   If a GCS bucket is removed while rowset or COPY recycle metadata still 
exists, this factory change makes file-list cleanup fail indefinitely. The old 
`GcsAccessor::delete_files` called `delete_file`, which normalized HTTP 
404/`NOT_FOUND` to success. The inherited `S3Accessor::delete_files` instead 
forwards `DeleteObjects` through `S3ObjStorageClient::delete_objects`, which 
returns nonzero `NOT_FOUND` for a missing bucket ([GCS XML error 
reference](https://docs.cloud.google.com/storage/docs/xml-api/reference-status)).
 Consequently `InstanceRecycler::delete_rowset_data` and COPY cleanup retain 
their KV entries on every retry even though no physical data remains. Preserve 
the previous not-found-as-success behavior for GCS batch deletion and cover a 
whole-request missing-bucket response in a test.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to