This commit is contained in:
Sema Checherinda 2024-11-06 16:44:52 +01:00
parent 338af374d8
commit df632b6f1e
8 changed files with 0 additions and 67 deletions

View File

@ -277,19 +277,6 @@ void AzureObjectStorage::removeObjectImpl(const StoredObject & object, const Sha
}
}
/// Remove file. Throws exception if file doesn't exists or it's a directory.
// void AzureObjectStorage::removeObject(const StoredObject & object)
// {
// removeObjectImpl(object, client.get(), false);
// }
// void AzureObjectStorage::removeObjects(const StoredObjects & objects)
// {
// auto client_ptr = client.get();
// for (const auto & object : objects)
// removeObjectImpl(object, client_ptr, false);
// }
void AzureObjectStorage::removeObjectIfExists(const StoredObject & object)
{
removeObjectImpl(object, client.get(), true);

View File

@ -59,11 +59,6 @@ public:
size_t buf_size = DBMS_DEFAULT_BUFFER_SIZE,
const WriteSettings & write_settings = {}) override;
/// Remove file. Throws exception if file doesn't exists or it's a directory.
//void removeObject(const StoredObject & object) override;
//void removeObjects(const StoredObjects & objects) override;
void removeObjectIfExists(const StoredObject & object) override;
void removeObjectsIfExist(const StoredObjects & objects) override;

View File

@ -148,20 +148,6 @@ void CachedObjectStorage::removeCacheIfExists(const std::string & path_key_for_c
cache->removeKeyIfExists(getCacheKey(path_key_for_cache), FileCache::getCommonUser().user_id);
}
// void CachedObjectStorage::removeObject(const StoredObject & object)
// {
// removeCacheIfExists(object.remote_path);
// object_storage->removeObject(object);
// }
// void CachedObjectStorage::removeObjects(const StoredObjects & objects)
// {
// for (const auto & object : objects)
// removeCacheIfExists(object.remote_path);
// object_storage->removeObjects(objects);
// }
void CachedObjectStorage::removeObjectIfExists(const StoredObject & object)
{
removeCacheIfExists(object.remote_path);

View File

@ -45,10 +45,6 @@ public:
size_t buf_size = DBMS_DEFAULT_BUFFER_SIZE,
const WriteSettings & write_settings = {}) override;
// void removeObject(const StoredObject & object) override;
// void removeObjects(const StoredObjects & objects) override;
void removeObjectIfExists(const StoredObject & object) override;
void removeObjectsIfExist(const StoredObjects & objects) override;

View File

@ -326,21 +326,11 @@ void S3ObjectStorage::removeObjectsImpl(const StoredObjects & objects, bool if_e
ProfileEvents::DiskS3DeleteObjects);
}
// void S3ObjectStorage::removeObject(const StoredObject & object)
// {
// removeObjectImpl(object, false);
// }
void S3ObjectStorage::removeObjectIfExists(const StoredObject & object)
{
removeObjectImpl(object, true);
}
// void S3ObjectStorage::removeObjects(const StoredObjects & objects)
// {
// removeObjectsImpl(objects, false);
// }
void S3ObjectStorage::removeObjectsIfExist(const StoredObjects & objects)
{
removeObjectsImpl(objects, true);

View File

@ -101,13 +101,6 @@ public:
ObjectStorageIteratorPtr iterate(const std::string & path_prefix, size_t max_keys) const override;
/// Uses `DeleteObjectRequest`.
//void removeObject(const StoredObject & object) override;
/// Uses `DeleteObjectsRequest` if it is allowed by `s3_capabilities`, otherwise `DeleteObjectRequest`.
/// `DeleteObjectsRequest` is not supported on GCS, see https://issuetracker.google.com/issues/162653700 .
//void removeObjects(const StoredObjects & objects) override;
/// Uses `DeleteObjectRequest`.
void removeObjectIfExists(const StoredObject & object) override;

View File

@ -254,16 +254,6 @@ std::unique_ptr<WriteBufferFromFileBase> WebObjectStorage::writeObject( /// NOLI
throwNotAllowed();
}
// void WebObjectStorage::removeObject(const StoredObject &)
// {
// throwNotAllowed();
// }
// void WebObjectStorage::removeObjects(const StoredObjects &)
// {
// throwNotAllowed();
// }
void WebObjectStorage::removeObjectIfExists(const StoredObject &)
{
throwNotAllowed();

View File

@ -47,10 +47,6 @@ public:
size_t buf_size = DBMS_DEFAULT_BUFFER_SIZE,
const WriteSettings & write_settings = {}) override;
// void removeObject(const StoredObject & object) override;
// void removeObjects(const StoredObjects & objects) override;
void removeObjectIfExists(const StoredObject & object) override;
void removeObjectsIfExist(const StoredObjects & objects) override;