Test lần 2
Some checks failed
Test / test (push) Has been cancelled

This commit is contained in:
2026-06-13 13:58:38 +07:00
parent d6f22132ce
commit fbc0c11be2
13 changed files with 239 additions and 68 deletions

View File

@@ -3,7 +3,6 @@
#include "util/file_util.hpp"
#include "util/id_util.hpp"
#include <algorithm>
#include <chrono>
#include <stdexcept>
#include <thread>
@@ -97,12 +96,6 @@ void MissionQueue::ensureRunnerDefaults()
runner_["paused"] = false;
}
void MissionQueue::saveLocked() const
{
std::lock_guard<std::recursive_mutex> lock(mu_);
saveUnlocked();
}
void MissionQueue::startWorkerIfNeeded()
{
if (worker_.joinable())

View File

@@ -51,7 +51,6 @@ private:
const nlohmann::json& parameters,
nlohmann::json& log,
int loop_depth);
void saveLocked() const;
void sleepMs(int ms);
void setRunnerState(const std::string& state, const std::string& message = "");
void insertByPriorityUnlocked(nlohmann::json& entry);

View File

@@ -55,11 +55,6 @@ nlohmann::json ModbusTriggerService::coilStates() const
return out;
}
void ModbusTriggerService::onCoilRisingEdgeUnlocked(int coil_id)
{
(void)coil_id;
}
bool ModbusTriggerService::writeCoil(int coil_id, bool value, std::string& err)
{
if (!coilIdValid(coil_id))

View File

@@ -40,7 +40,6 @@ private:
std::atomic<bool> stop_{false};
std::thread tcp_thread_;
void onCoilRisingEdgeUnlocked(int coil_id);
void tcpLoop();
void handleTcpClient(int client_fd);
};

View File

@@ -5,15 +5,6 @@
namespace lm {
namespace {
nlohmann::json mirError(const std::string& msg)
{
return nlohmann::json{{"error", msg}, {"error_code", 400}};
}
} // namespace
bool ApiServer::enqueueRequest(const nlohmann::json& request, httplib::Response& res, int status_code)
{
nlohmann::json payload;