#include #include #include #include #include #include #include "mix_cc/debug/pre_define.h" using namespace baosight; dsm::dsm() { logger_ = std::make_unique("dsm"); } dsm::~dsm() { logger_->Info() << "-------dsm::end-------" << std::endl; } int dsm::start() { logger_->Info() << "-------dsm::start-------" << std::endl; con_mag_ = std::make_shared(); con_mag_->dbLogin(); try { auto module_name = name(); dsm_server = new dsmICEI(); this->add(string("baosight/") + name(), dsm_server); } catch (::Ice::LocalException& e) { logger_->Error() << "Can not add baosight/dsm, error: " << e << endl; return (-1); } return 0; } // PACE_SERVER_INSTALL(dsm) //应用程序主入口,传入参数为定义的类名 PACE_PLATFORM_SERVER_INSTALL(dsm, APPVERSION);