Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hilo-socketCenter
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujiebin
hilo-socketCenter
Commits
833f2a9b
Commit
833f2a9b
authored
Dec 04, 2023
by
hujiebin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:优化告警
parent
f8a02c60
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
main.go
main.go
+6
-6
No files found.
main.go
View file @
833f2a9b
...
...
@@ -11,7 +11,6 @@ import (
"google.golang.org/grpc/resolver"
"google.golang.org/grpc/resolver/manual"
"hilo-socketCenter/common"
"hilo-socketCenter/common/dingding"
"hilo-socketCenter/common/mylogrus"
"hilo-socketCenter/common/redisCli"
"hilo-socketCenter/domain/model/rpc_m"
...
...
@@ -113,11 +112,12 @@ func check() {
mylogrus
.
MyLog
.
Infof
(
"cron sendGiftChan msg error,left %v-%v"
,
l
,
err
)
}
if
l
>
MONITOR_LENGTH
{
go
func
()
{
if
sErr
:=
dingding
.
SendDingRobot
(
dingding
.
ROBOTWEBHOOK
,
fmt
.
Sprintf
(
"送礼横幅变化通知延迟,队列%s长度:%d"
,
SocketQueueSendGift
,
l
),
true
);
sErr
!=
nil
{
mylogrus
.
MyLog
.
Errorf
(
"dingding msg fail:%v"
,
sErr
)
}
}()
mylogrus
.
MyLog
.
Infof
(
"送礼横幅变化通知延迟,队列%s长度:%d"
,
SocketQueueSendGift
,
l
)
//go func() {
// if sErr := dingding.SendDingRobot(dingding.ROBOTWEBHOOK, fmt.Sprintf("送礼横幅变化通知延迟,队列%s长度:%d", SocketQueueSendGift, l), true); sErr != nil {
// mylogrus.MyLog.Errorf("dingding msg fail:%v", sErr)
// }
//}()
n
,
err
:=
redisCli
.
GetRedisCluster
()
.
Del
(
context
.
Background
(),
SocketQueueSendGift
)
.
Result
()
mylogrus
.
MyLog
.
Infof
(
"del sendGiftChan msg queue:%v,n:%v,err:%v"
,
SocketQueueSendGift
,
n
,
err
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment