v1.5.1 增强程序稳定性

This commit is contained in:
robin
2026-03-22 17:37:40 +08:00
parent afbaaa869c
commit 17e182b413
652 changed files with 22949 additions and 34397 deletions

View File

@@ -364,6 +364,9 @@ func (this *HTTPRequestStatManager) Upload() error {
// 城市
for k, stat := range cityMap {
var pieces = strings.SplitN(k, "@", 4)
if len(pieces) < 4 {
continue
}
var serverId = types.Int64(pieces[0])
pbCities = append(pbCities, &pb.UploadServerHTTPRequestStatRequest_RegionCity{
ServerId: serverId,
@@ -397,6 +400,9 @@ func (this *HTTPRequestStatManager) Upload() error {
// 运营商
for k, count := range providerMap {
var pieces = strings.SplitN(k, "@", 2)
if len(pieces) < 2 {
continue
}
var serverId = types.Int64(pieces[0])
pbProviders = append(pbProviders, &pb.UploadServerHTTPRequestStatRequest_RegionProvider{
ServerId: serverId,
@@ -425,6 +431,9 @@ func (this *HTTPRequestStatManager) Upload() error {
// 操作系统
for k, count := range systemMap {
var pieces = strings.SplitN(k, "@", 3)
if len(pieces) < 3 {
continue
}
var serverId = types.Int64(pieces[0])
pbSystems = append(pbSystems, &pb.UploadServerHTTPRequestStatRequest_System{
ServerId: serverId,
@@ -454,6 +463,9 @@ func (this *HTTPRequestStatManager) Upload() error {
// 浏览器
for k, count := range browserMap {
var pieces = strings.SplitN(k, "@", 3)
if len(pieces) < 3 {
continue
}
var serverId = types.Int64(pieces[0])
pbBrowsers = append(pbBrowsers, &pb.UploadServerHTTPRequestStatRequest_Browser{
ServerId: serverId,