mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-26 09:32:01 +00:00
Merge pull request #50976 from kssenii/fix-data-lakes-too-many-head-requests
Fix data lakes slowness because of synchronous head requests
This commit is contained in:
commit
c15e7b93cb
@ -460,7 +460,10 @@ public:
|
|||||||
for (auto && key : all_keys)
|
for (auto && key : all_keys)
|
||||||
{
|
{
|
||||||
std::optional<S3::ObjectInfo> info;
|
std::optional<S3::ObjectInfo> info;
|
||||||
if (need_total_size)
|
/// In case all_keys.size() > 1, avoid getting object info now
|
||||||
|
/// (it will be done anyway eventually, but with delay and in parallel).
|
||||||
|
/// But progress bar will not work in this case.
|
||||||
|
if (need_total_size && all_keys.size() == 1)
|
||||||
{
|
{
|
||||||
info = S3::getObjectInfo(client_, bucket, key, version_id_, request_settings_);
|
info = S3::getObjectInfo(client_, bucket, key, version_id_, request_settings_);
|
||||||
total_size += info->size;
|
total_size += info->size;
|
||||||
|
Loading…
Reference in New Issue
Block a user