实现HTTP服务架构

This commit is contained in:
lixiaoyuan
2025-08-31 14:38:53 +08:00
parent 4af4e670d2
commit e0b64a20c4
46 changed files with 1436 additions and 545 deletions

View File

@@ -4,6 +4,7 @@
#include "common/JsonN.h"
#include "Logger.h"
#include "AppData.h"
AppOption Config::option;
@@ -34,5 +35,11 @@ bool Config::init(std::string filename)
XLOGI() << "[APP] load database config error: not found. host=" << option.database.host;
}
if (jsonroot.contains("token"))
{
std::string token = jsonroot["token"];
option.useToken = !token.empty();
}
return true;
}