This commit is contained in:
Sergey Katkovskiy 2023-05-25 23:40:26 +03:00
parent d2b8dd3ae9
commit 528fa9ae04
2 changed files with 2 additions and 3 deletions

View File

@ -109,10 +109,9 @@ StorageS3Queue::StorageS3Queue(
, distributed_processing(distributed_processing_)
, format_settings(format_settings_)
, partition_by(partition_by_)
, is_key_with_globs(s3_configuration.url.key.find_first_of("*?{") != std::string::npos)
, log(&Poco::Logger::get("StorageS3Queue (" + table_id_.table_name + ")"))
{
if (!is_key_with_globs)
if (!withGlobs())
{
throw Exception(ErrorCodes::QUERY_NOT_ALLOWED, "S3Queue engine can read only from url with globs");
}

View File

@ -95,9 +95,9 @@ private:
const bool distributed_processing;
std::optional<FormatSettings> format_settings;
ASTPtr partition_by;
bool is_key_with_globs = false;
bool supportsSubcolumns() const override;
bool withGlobs() const { return s3_configuration.url.key.find_first_of("*?{") != std::string::npos; }
void threadFunc();
size_t getTableDependentCount() const;