feat(access-logs): 新增 IP 明细 Tab 并完善日志详情字段

按时间窗聚合 IP 请求数/2xx 比例/入出站流量,支持排序与详情分析;
日志明细详情仅展示请求业务字段,IP 情报迁至独立详情弹窗。
This commit is contained in:
ryan
2026-07-19 00:42:59 +08:00
parent bfd9de69af
commit 920a530aa7
22 changed files with 2042 additions and 742 deletions
@@ -46,10 +46,16 @@ type NodeAccessLogIPAggregate struct {
// NodeAccessLogIPSummary is an IP summary row.
type NodeAccessLogIPSummary struct {
RemoteAddr string `gorm:"column:remote_addr"`
TotalRequests int64 `gorm:"column:total_requests"`
RecentRequests int64 `gorm:"column:recent_requests"`
LastSeenEpoch int64 `gorm:"column:last_seen_epoch"`
RemoteAddr string `gorm:"column:remote_addr"`
Region string `gorm:"column:region"`
TotalRequests int64 `gorm:"column:total_requests"`
Success2xxCount int64 `gorm:"column:success_2xx_count"`
SuccessRatio float64 `gorm:"column:success_ratio"`
BytesReceived int64 `gorm:"column:request_length"`
BytesSent int64 `gorm:"column:bytes_sent"`
// RecentRequests is deprecated (always 0); kept for wire compatibility.
RecentRequests int64 `gorm:"column:recent_requests"`
LastSeenEpoch int64 `gorm:"column:last_seen_epoch"`
}
// NodeAccessLogIPTrend is an IP trend bucket row.