UniSet 2.32.1
Классы | Открытые типы | Открытые члены | Открытые статические члены | Защищенные типы | Защищенные члены | Защищенные статические члены | Защищенные данные | Полный список членов класса
Класс uniset::BackendClickHouse

#include <BackendClickHouse.h>

Граф наследования:uniset::BackendClickHouse:
Inheritance graph
[см. легенду]
Граф связей класса uniset::BackendClickHouse:
Collaboration graph
[см. легенду]

Классы

struct  ParamInfo
 

Открытые типы

enum  Timers { tmFlushBuffer , tmReconnect , tmLastNumberOfTimer }
 

Открытые члены

 BackendClickHouse (uniset::ObjectId objId, xmlNode *cnode, uniset::ObjectId shmID, const std::shared_ptr< SharedMemory > &ic=nullptr, const std::string &prefix="clickhouse")
 
std::shared_ptr< LogAgregatorgetLogAggregator ()
 
std::shared_ptr< DebugStreamlog ()
 
- Открытые члены унаследованные от UObject_SK
 UObject_SK (uniset::ObjectId id, xmlNode *node=uniset::uniset_conf() ->getNode("UObject"), const std::string &argprefix="", xmlNode *globalConfNode=nullptr)
 
long getValue (uniset::ObjectId sid)
 
void setValue (uniset::ObjectId sid, long value)
 
void askSensor (uniset::ObjectId sid, UniversalIO::UIOCommand, uniset::ObjectId node=uniset::uniset_conf() ->getLocalNode())
 
virtual uniset::SimpleInfogetInfo (const char *userparam) override
 
std::shared_ptr< DebugStreamlog () noexcept
 
std::shared_ptr< uniset::LogAgregatorlogAgregator () noexcept
 
void init_dlog (std::shared_ptr< DebugStream > d) noexcept
 
std::string dumpVars ()
 
std::string help () const noexcept
 
virtual Poco::JSON::Object::Ptr httpGet (const Poco::URI::QueryParameters &p) override
 
virtual Poco::JSON::Object::Ptr httpRequest (const std::string &req, const Poco::URI::QueryParameters &p) override
 
virtual Poco::JSON::Object::Ptr httpHelp (const Poco::URI::QueryParameters &p) override
 
- Открытые члены унаследованные от uniset::UniSetObject
 UniSetObject (const std::string &name, const std::string &section)
 
 UniSetObject (uniset::ObjectId id)
 
virtual CORBA::Boolean exist () override
 
virtual uniset::ObjectId getId () override
 
const uniset::ObjectId getId () const
 
std::string getName () const
 
virtual uniset::ObjectType getType () override
 
const std::string getStrType ()
 
virtual uniset::SimpleInfoapiRequest (const char *query) override
 
virtual void push (const uniset::TransportMessage &msg) override
 поместить сообщение в очередь
 
virtual void pushMessage (const char *msg, ::CORBA::Long mtype, const ::uniset::Timespec &tm, const ::uniset::ProducerInfo &pi, ::CORBA::Long priority, ::CORBA::Long consumer) override
 поместить текстовое сообщение в очередь
 
uniset::ObjectPtr getRef () const
 
std::shared_ptr< UniSetObjectget_ptr ()
 
virtual timeout_t askTimer (uniset::TimerId timerid, timeout_t timeMS, clock_t ticks=-1, uniset::Message::Priority p=uniset::Message::High) override
 
- Открытые члены унаследованные от uniset::LT_Object
timeout_t checkTimers (UniSetObject *obj)
 
timeout_t getTimeInterval (uniset::TimerId timerid) const
 
timeout_t getTimeLeft (uniset::TimerId timerid) const
 

Открытые статические члены

static std::shared_ptr< BackendClickHouseinit_clickhouse (int argc, const char *const *argv, uniset::ObjectId shmID, const std::shared_ptr< SharedMemory > &ic=nullptr, const std::string &prefix="clickhouse")
 
static void help_print (int argc, const char *const *argv)
 

Защищенные типы

using Tag = std::pair<std::string, std::string>
 
using TagList = std::vector<Tag>
 
- Защищенные типы унаследованные от uniset::LT_Object
typedef std::deque< TimerInfoTimersList
 

Защищенные члены

virtual void callback () noexcept override
 
virtual void askSensors (UniversalIO::UIOCommand cmd) override
 
virtual void sensorInfo (const uniset::SensorMessage *sm) override
 
virtual void timerInfo (const uniset::TimerMessage *tm) override
 
virtual void sysCommand (const uniset::SystemMessage *sm) override
 
virtual std::string getMonitInfo () const override
 
void init (xmlNode *cnode)
 
bool flushBuffer ()
 
bool reconnect ()
 
void createColumns ()
 
void clearData ()
 
- Защищенные члены унаследованные от UObject_SK
virtual void processingMessage (const uniset::VoidMessage *msg) override
 
virtual bool activateObject () override
 Активизация объекта (переопределяется для необходимых действий после активизации)
 
virtual bool deactivateObject () override
 Деактивация объекта (переопределяется для необходимых действий при завершении работы)
 
virtual std::string getTypeOfMessage (int t) const
 
virtual void httpGetUserData (Poco::JSON::Object::Ptr &jdata)
 
virtual Poco::JSON::Object::Ptr httpDumpIO ()
 
virtual Poco::JSON::Object::Ptr httpRequestLog (const Poco::URI::QueryParameters &p)
 
virtual Poco::JSON::Object::Ptr request_params_set (const std::string &req, const Poco::URI::QueryParameters &p) override
 
virtual Poco::JSON::Object::Ptr request_params_get (const std::string &req, const Poco::URI::QueryParameters &p) override
 
void preAskSensors (UniversalIO::UIOCommand cmd)
 
void preSysCommand (const uniset::SystemMessage *sm)
 
bool waitSM (int wait_msec, uniset::ObjectId testID=uniset::DefaultObjectId)
 
uniset::ObjectId getSMTestID () const
 
int getIntProp (const std::string &name)
 
const std::string getProp (const std::string &name)
 
- Защищенные члены унаследованные от uniset::UniSetObject
virtual void onTextMessage (const uniset::TextMessage *tm)
 
VoidMessagePtr receiveMessage ()
 
VoidMessagePtr waitMessage (timeout_t msec=UniSetTimer::WaitUpTime)
 
void termWaiting ()
 
size_t countMessages ()
 
size_t getCountOfLostMessages () const
 
void uterminate ()
 
void thread (bool create)
 
void offThread ()
 
void onThread ()
 
void setID (uniset::ObjectId id)
 
void setThreadPriority (Poco::Thread::Priority p)
 
void setMaxSizeOfMessageQueue (size_t s)
 
size_t getMaxSizeOfMessageQueue () const
 
bool isActive () const
 
void setActive (bool set)
 
virtual Poco::JSON::Object::Ptr httpGetMyInfo (Poco::JSON::Object::Ptr root)
 
Poco::JSON::Object::Ptr request_configure (const std::string &req, const Poco::URI::QueryParameters &p)
 
Poco::JSON::Object::Ptr request_configure_get (const std::string &req, const Poco::URI::QueryParameters &p)
 
Poco::JSON::Object::Ptr request_configure_by_name (const std::string &name, const std::string &props)
 
Poco::JSON::Object::Ptr request_params (const std::string &req, const Poco::URI::QueryParameters &p)
 
- Защищенные члены унаследованные от uniset::LT_Object
virtual std::string getTimerName (int id) const
 
TimersList getTimersList () const
 

Защищенные статические члены

static TagList parseTags (const std::string &tags)
 

Защищенные данные

std::shared_ptr< SMInterfaceshm
 
std::unordered_map< uniset::ObjectId, ParamInfoclickhouseParams
 
TagList globalTags
 
timeout_t bufSyncTime = { 5000 }
 
size_t bufSize = { 5000 }
 
size_t bufMaxSize = { 100000 }
 
bool timerIsOn = { false }
 
timeout_t reconnectTime = { 5000 }
 
std::string lastError
 
std::shared_ptr< clickhouse::ColumnDateTime64 > colTimeStamp
 
std::shared_ptr< clickhouse::ColumnFloat64 > colValue
 
std::shared_ptr< clickhouse::ColumnString > colName
 
std::shared_ptr< clickhouse::ColumnString > colNodeName
 
std::shared_ptr< clickhouse::ColumnString > colProducer
 
std::shared_ptr< clickhouse::ColumnArray > arrTagKeys
 
std::shared_ptr< clickhouse::ColumnArray > arrTagValues
 
std::unique_ptr< uniset::ClickHouseTagsConfigdyntags
 
std::string fullTableName
 
std::unique_ptr< ClickHouseInterfacedb
 
std::string dbhost
 
int dbport
 
std::string dbuser
 
std::string dbpass
 
std::string dbname
 
- Защищенные данные унаследованные от UObject_SK
bool active
 
const std::string argprefix
 
uniset::ObjectId smTestID
 
uniset::PassiveTimer ptHeartBeat
 
uniset::ObjectId idHeartBeat
 
long maxHeartBeat
 
xmlNode * confnode
 
uniset::timeout_t smReadyTimeout
 
std::atomic_bool activated = { false }
 
std::atomic_bool canceled = { false }
 
uniset::timeout_t activateTimeout
 
uniset::PassiveTimer ptStartUpTimeout
 
int askPause
 
IOController_i::SensorInfo si
 
std::shared_ptr< uniset::LogAgregatorloga
 
std::shared_ptr< DebugStreammylog
 
std::shared_ptr< uniset::LogServerlogserv
 
std::string logserv_host = {""}
 
int logserv_port = {0}
 
uniset::VMonitor vmon
 
- Защищенные данные унаследованные от uniset::UniSetObject
std::shared_ptr< UInterfaceui
 
std::string myname
 
std::weak_ptr< UniSetManagermymngr
 
- Защищенные данные унаследованные от uniset::LT_Object
timeout_t sleepTime
 

Подробное описание

Реализация DBServer для Clickhouse

Методы

◆ askSensors()

void BackendClickHouse::askSensors ( UniversalIO::UIOCommand cmd)
overrideprotectedvirtual

Переопределяет метод предка UObject_SK.

◆ callback()

void BackendClickHouse::callback ( )
overrideprotectedvirtualnoexcept

функция вызываемая из потока

Переопределяет метод предка UObject_SK.

◆ getMonitInfo()

std::string BackendClickHouse::getMonitInfo ( ) const
overrideprotectedvirtual

пользовательская информация выводимая в getInfo()

Переопределяет метод предка UObject_SK.

◆ help_print()

void BackendClickHouse::help_print ( int argc,
const char *const * argv )
static

глобальная функция для вывода help-а

◆ init_clickhouse()

std::shared_ptr< BackendClickHouse > BackendClickHouse::init_clickhouse ( int argc,
const char *const * argv,
uniset::ObjectId shmID,
const std::shared_ptr< SharedMemory > & ic = nullptr,
const std::string & prefix = "clickhouse" )
static

глобальная функция для инициализации объекта

◆ sensorInfo()

void BackendClickHouse::sensorInfo ( const uniset::SensorMessage * sm)
overrideprotectedvirtual

Переопределяет метод предка UObject_SK.

◆ sysCommand()

void BackendClickHouse::sysCommand ( const uniset::SystemMessage * sm)
overrideprotectedvirtual

Переопределяет метод предка UObject_SK.

◆ timerInfo()

void BackendClickHouse::timerInfo ( const uniset::TimerMessage * tm)
overrideprotectedvirtual

Переопределяет метод предка UObject_SK.