2018-08-25 13:55:18 +00:00
|
|
|
#pragma once
|
|
|
|
|
2019-06-03 00:57:33 +00:00
|
|
|
#include <string>
|
2018-08-25 13:55:18 +00:00
|
|
|
#include <Core/Protocol.h>
|
|
|
|
#include <IO/ConnectionTimeouts.h>
|
|
|
|
|
2019-06-03 00:57:33 +00:00
|
|
|
namespace Poco::Util
|
2018-08-25 13:55:18 +00:00
|
|
|
{
|
2019-06-03 00:57:33 +00:00
|
|
|
class AbstractConfiguration;
|
2018-08-25 13:55:18 +00:00
|
|
|
}
|
|
|
|
|
2019-06-03 00:57:33 +00:00
|
|
|
namespace DB
|
|
|
|
{
|
2018-08-25 13:55:18 +00:00
|
|
|
struct ConnectionParameters
|
|
|
|
{
|
2019-06-03 00:57:33 +00:00
|
|
|
std::string host;
|
2019-01-19 23:27:52 +00:00
|
|
|
UInt16 port{};
|
2019-06-03 00:57:33 +00:00
|
|
|
std::string default_database;
|
|
|
|
std::string user;
|
|
|
|
std::string password;
|
2019-01-19 23:27:52 +00:00
|
|
|
Protocol::Secure security = Protocol::Secure::Disable;
|
|
|
|
Protocol::Compression compression = Protocol::Compression::Enable;
|
2018-08-25 13:55:18 +00:00
|
|
|
ConnectionTimeouts timeouts;
|
|
|
|
|
|
|
|
ConnectionParameters() {}
|
|
|
|
|
2019-06-03 00:57:33 +00:00
|
|
|
ConnectionParameters(const Poco::Util::AbstractConfiguration & config);
|
2018-08-25 13:55:18 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|