ClickHouse/src/Storages/StorageMongoDBSocketFactory.h
OmarBazaraa a665cd3308 Fixes
2021-07-29 08:38:39 +00:00

20 lines
561 B
C++

#pragma once
#include <Poco/MongoDB/Connection.h>
namespace DB
{
class StorageMongoDBSocketFactory : public Poco::MongoDB::Connection::SocketFactory
{
public:
virtual Poco::Net::StreamSocket createSocket(const std::string & host, int port, Poco::Timespan connectTimeout, bool secure) override;
private:
static Poco::Net::StreamSocket createPlainSocket(const std::string & host, int port, Poco::Timespan connectTimeout);
static Poco::Net::StreamSocket createSecureSocket(const std::string & host, int port, Poco::Timespan connectTimeout);
};
}