| 232 | } |
| 233 | |
| 234 | void LlmProxyService::UpdateSettings(const settings::LlmProxySettings& settings) { |
| 235 | std::lock_guard<std::mutex> lock(settings_mutex_); |
| 236 | bool was_logging = settings_.enable_logging; |
| 237 | settings_ = settings; |
| 238 | |
| 239 | if (settings.enable_logging && !was_logging) { |
| 240 | OpenLogFile(); |
| 241 | LOG_INFO("LLM request logging enabled -> %s", log_dir_.c_str()); |
| 242 | } else if (!settings.enable_logging && was_logging) { |
| 243 | LOG_INFO("LLM request logging disabled"); |
| 244 | CloseLogFile(); |
| 245 | } |
| 246 | } |
| 247 | |
| 248 | void LlmProxyService::ServerThread() { |
| 249 | while (running_) { |
no test coverage detected