mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-16 12:44:42 +00:00
34 lines
672 B
C++
34 lines
672 B
C++
#include "LibraryBridge.h"
|
|
|
|
#include <iostream>
|
|
|
|
int mainEntryClickHouseLibraryBridge(int argc, char ** argv)
|
|
{
|
|
DB::LibraryBridge app;
|
|
try
|
|
{
|
|
return app.run(argc, argv);
|
|
}
|
|
catch (...)
|
|
{
|
|
std::cerr << DB::getCurrentExceptionMessage(true) << "\n";
|
|
auto code = DB::getCurrentExceptionCode();
|
|
return code ? code : 1;
|
|
}
|
|
}
|
|
|
|
namespace DB
|
|
{
|
|
|
|
std::string LibraryBridge::bridgeName() const
|
|
{
|
|
return "LibraryBridge";
|
|
}
|
|
|
|
LibraryBridge::HandlerFactoryPtr LibraryBridge::getHandlerFactoryPtr(ContextPtr context) const
|
|
{
|
|
return std::make_shared<LibraryBridgeHandlerFactory>("LibraryRequestHandlerFactory", context);
|
|
}
|
|
|
|
}
|