mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-27 18:12:02 +00:00
Better name
This commit is contained in:
parent
9bb681c104
commit
2228107134
@ -32,24 +32,24 @@ IAsynchronousReader & getThreadPoolReader(FilesystemReaderType type)
|
|||||||
{
|
{
|
||||||
case FilesystemReaderType::ASYNCHRONOUS_REMOTE_FS_READER:
|
case FilesystemReaderType::ASYNCHRONOUS_REMOTE_FS_READER:
|
||||||
{
|
{
|
||||||
static auto asynchronous_remote_fs_reader = getThreadPoolReaderImpl(type, config);
|
static auto asynchronous_remote_fs_reader = createThreadPoolReader(type, config);
|
||||||
return *asynchronous_remote_fs_reader;
|
return *asynchronous_remote_fs_reader;
|
||||||
}
|
}
|
||||||
case FilesystemReaderType::ASYNCHRONOUS_LOCAL_FS_READER:
|
case FilesystemReaderType::ASYNCHRONOUS_LOCAL_FS_READER:
|
||||||
{
|
{
|
||||||
static auto asynchronous_local_fs_reader = getThreadPoolReaderImpl(type, config);
|
static auto asynchronous_local_fs_reader = createThreadPoolReader(type, config);
|
||||||
return *asynchronous_local_fs_reader;
|
return *asynchronous_local_fs_reader;
|
||||||
}
|
}
|
||||||
case FilesystemReaderType::SYNCHRONOUS_LOCAL_FS_READER:
|
case FilesystemReaderType::SYNCHRONOUS_LOCAL_FS_READER:
|
||||||
{
|
{
|
||||||
static auto synchronous_local_fs_reader = getThreadPoolReaderImpl(type, config);
|
static auto synchronous_local_fs_reader = createThreadPoolReader(type, config);
|
||||||
return *synchronous_local_fs_reader;
|
return *synchronous_local_fs_reader;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unique_ptr<IAsynchronousReader> getThreadPoolReaderImpl(
|
std::unique_ptr<IAsynchronousReader> createThreadPoolReader(
|
||||||
FilesystemReaderType type, const Poco::Util::AbstractConfiguration & config)
|
FilesystemReaderType type, const Poco::Util::AbstractConfiguration & config)
|
||||||
{
|
{
|
||||||
switch (type)
|
switch (type)
|
||||||
|
@ -16,7 +16,7 @@ enum class FilesystemReaderType
|
|||||||
|
|
||||||
IAsynchronousReader & getThreadPoolReader(FilesystemReaderType type);
|
IAsynchronousReader & getThreadPoolReader(FilesystemReaderType type);
|
||||||
|
|
||||||
std::unique_ptr<IAsynchronousReader> getThreadPoolReaderImpl(
|
std::unique_ptr<IAsynchronousReader> createThreadPoolReader(
|
||||||
FilesystemReaderType type,
|
FilesystemReaderType type,
|
||||||
const Poco::Util::AbstractConfiguration & config);
|
const Poco::Util::AbstractConfiguration & config);
|
||||||
|
|
||||||
|
@ -4178,20 +4178,20 @@ IAsynchronousReader & Context::getThreadPoolReader(FilesystemReaderType type) co
|
|||||||
case FilesystemReaderType::ASYNCHRONOUS_REMOTE_FS_READER:
|
case FilesystemReaderType::ASYNCHRONOUS_REMOTE_FS_READER:
|
||||||
{
|
{
|
||||||
if (!shared->asynchronous_remote_fs_reader)
|
if (!shared->asynchronous_remote_fs_reader)
|
||||||
shared->asynchronous_remote_fs_reader = getThreadPoolReaderImpl(type, getConfigRef());
|
shared->asynchronous_remote_fs_reader = createThreadPoolReader(type, getConfigRef());
|
||||||
return *shared->asynchronous_remote_fs_reader;
|
return *shared->asynchronous_remote_fs_reader;
|
||||||
}
|
}
|
||||||
case FilesystemReaderType::ASYNCHRONOUS_LOCAL_FS_READER:
|
case FilesystemReaderType::ASYNCHRONOUS_LOCAL_FS_READER:
|
||||||
{
|
{
|
||||||
if (!shared->asynchronous_local_fs_reader)
|
if (!shared->asynchronous_local_fs_reader)
|
||||||
shared->asynchronous_local_fs_reader = getThreadPoolReaderImpl(type, getConfigRef());
|
shared->asynchronous_local_fs_reader = createThreadPoolReader(type, getConfigRef());
|
||||||
|
|
||||||
return *shared->asynchronous_local_fs_reader;
|
return *shared->asynchronous_local_fs_reader;
|
||||||
}
|
}
|
||||||
case FilesystemReaderType::SYNCHRONOUS_LOCAL_FS_READER:
|
case FilesystemReaderType::SYNCHRONOUS_LOCAL_FS_READER:
|
||||||
{
|
{
|
||||||
if (!shared->synchronous_local_fs_reader)
|
if (!shared->synchronous_local_fs_reader)
|
||||||
shared->synchronous_local_fs_reader = getThreadPoolReaderImpl(type, getConfigRef());
|
shared->synchronous_local_fs_reader = createThreadPoolReader(type, getConfigRef());
|
||||||
|
|
||||||
return *shared->synchronous_local_fs_reader;
|
return *shared->synchronous_local_fs_reader;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user