mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-04 13:32:13 +00:00
4fe1c9a78f
to allow ExternalLoader::reloadConfig() work for generated configurations too.
35 lines
959 B
C++
35 lines
959 B
C++
#include "ExternalLoaderDictionaryStorageConfigRepository.h"
|
|
|
|
#include <Interpreters/Context.h>
|
|
#include <Storages/StorageDictionary.h>
|
|
|
|
namespace DB
|
|
{
|
|
|
|
ExternalLoaderDictionaryStorageConfigRepository::ExternalLoaderDictionaryStorageConfigRepository(const StorageDictionary & dictionary_storage_)
|
|
: dictionary_storage(dictionary_storage_)
|
|
{
|
|
}
|
|
|
|
std::string ExternalLoaderDictionaryStorageConfigRepository::getName() const
|
|
{
|
|
return dictionary_storage.getStorageID().getInternalDictionaryName();
|
|
}
|
|
|
|
std::set<std::string> ExternalLoaderDictionaryStorageConfigRepository::getAllLoadablesDefinitionNames()
|
|
{
|
|
return { getName() };
|
|
}
|
|
|
|
bool ExternalLoaderDictionaryStorageConfigRepository::exists(const std::string & loadable_definition_name)
|
|
{
|
|
return getName() == loadable_definition_name;
|
|
}
|
|
|
|
LoadablesConfigurationPtr ExternalLoaderDictionaryStorageConfigRepository::load(const std::string &)
|
|
{
|
|
return dictionary_storage.getConfiguration();
|
|
}
|
|
|
|
}
|