修复: 升级框架并完善报告导出

- 升级 Drogon 和 Trantor,修复畸形请求导致的连接计数泄漏\n- 增加第三方框架版本校验与自动重建\n- 完善完整报告导出和接口文档
This commit is contained in:
cloud
2026-08-10 09:50:09 +08:00
parent 99ed321d24
commit 0e28826073
82 changed files with 3095 additions and 566 deletions
+15
View File
@@ -21,6 +21,21 @@
# ##############################################################################
include(FindPackageHandleStandardArgs)
# On Apple Silicon Macs, Homebrew installs to /opt/homebrew instead of
# /usr/local (Intel Macs). Detect the prefix dynamically so cmake finds
# dependencies regardless of Mac architecture.
if(APPLE)
execute_process(
COMMAND brew --prefix brotli
OUTPUT_VARIABLE HOMEBREW_BROTLI_PREFIX
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
if(HOMEBREW_BROTLI_PREFIX)
list(APPEND CMAKE_PREFIX_PATH ${HOMEBREW_BROTLI_PREFIX})
endif()
endif()
find_path(BROTLI_INCLUDE_DIR "brotli/decode.h")
find_library(BROTLICOMMON_LIBRARY NAMES brotlicommon brotlicommon-static)
+15
View File
@@ -5,6 +5,21 @@
# HIREDIS_INCLUDE_DIRS - hiredis include directories
# HIREDIS_LIBRARIES - libraries need to use hiredis
# On Apple Silicon Macs, Homebrew installs to /opt/homebrew instead of
# /usr/local (Intel Macs). Detect the prefix dynamically so cmake finds
# dependencies regardless of Mac architecture.
if(APPLE)
execute_process(
COMMAND brew --prefix hiredis
OUTPUT_VARIABLE HOMEBREW_HIREDIS_PREFIX
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
if(HOMEBREW_HIREDIS_PREFIX)
list(APPEND CMAKE_PREFIX_PATH ${HOMEBREW_HIREDIS_PREFIX})
endif()
endif()
if (HIREDIS_INCLUDE_DIRS AND HIREDIS_LIBRARIES)
set(HIREDIS_FIND_QUIETLY TRUE)
set(Hiredis_FOUND TRUE)
+16
View File
@@ -10,6 +10,22 @@
# false, do not try to use jsoncpp.
# Jsoncpp_lib - The imported target library.
# On Apple Silicon Macs, Homebrew installs to /opt/homebrew instead of
# /usr/local (Intel Macs). Detect the prefix dynamically so cmake finds
# dependencies regardless of Mac architecture.
if(APPLE)
execute_process(
COMMAND brew --prefix jsoncpp
OUTPUT_VARIABLE HOMEBREW_JSONCPP_PREFIX
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
if(HOMEBREW_JSONCPP_PREFIX)
list(APPEND CMAKE_PREFIX_PATH ${HOMEBREW_JSONCPP_PREFIX})
endif()
endif()
# only look in default directories
find_path(JSONCPP_INCLUDE_DIRS
NAMES json/json.h
+15
View File
@@ -13,6 +13,21 @@
# SQLite3_FOUND - True if sqlite3 found.
# SQLite3_lib - The imported target library.
# On Apple Silicon Macs, Homebrew installs to /opt/homebrew instead of
# /usr/local (Intel Macs). Detect the prefix dynamically so cmake finds
# dependencies regardless of Mac architecture.
if(APPLE)
execute_process(
COMMAND brew --prefix sqlite3
OUTPUT_VARIABLE HOMEBREW_SQLITE3_PREFIX
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
if(HOMEBREW_SQLITE3_PREFIX)
list(APPEND CMAKE_PREFIX_PATH ${HOMEBREW_SQLITE3_PREFIX})
endif()
endif()
# Look for the header file.
find_path(SQLITE3_INCLUDE_DIRS NAMES sqlite3.h)
+15
View File
@@ -7,6 +7,21 @@
# PostgreSQL.
# pg_lib - The imported target library.
# On Apple Silicon Macs, Homebrew installs to /opt/homebrew instead of
# /usr/local (Intel Macs). Detect the prefix dynamically so cmake finds
# dependencies regardless of Mac architecture.
if(APPLE)
execute_process(
COMMAND brew --prefix libpq
OUTPUT_VARIABLE HOMEBREW_PG_PREFIX
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
if(HOMEBREW_PG_PREFIX)
list(APPEND CMAKE_PREFIX_PATH ${HOMEBREW_PG_PREFIX})
endif()
endif()
find_package(PostgreSQL)
if(PostgreSQL_FOUND)
set(PG_LIBRARIES ${PostgreSQL_LIBRARIES})