Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
ffm-baseline
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ML
ffm-baseline
Commits
421612ec
Commit
421612ec
authored
Nov 13, 2019
by
高雅喆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
监控
parent
681fb231
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
spark_streaming_monitor.py
eda/smart_rank/spark_streaming_monitor.py
+3
-3
No files found.
eda/smart_rank/spark_streaming_monitor.py
View file @
421612ec
...
...
@@ -16,10 +16,10 @@ while True:
is_email
=
0
for
batch
in
batchs_info
:
if
is_email
==
0
and
'totalDelay'
in
batch
and
batch
[
'totalDelay'
]
>
10000
:
batch_time
=
batch
[
'
totalDelay
'
]
batch_time
=
batch
[
'
batchTime
'
]
GMT_FORMAT
=
'
%
Y-
%
m-
%
dT
%
H:
%
M:
%
S.000GMT'
batch
Time_beijing
=
datetime
.
datetime
.
strptime
(
batchT
ime
,
GMT_FORMAT
)
+
datetime
.
timedelta
(
hours
=
8
)
send_email
(
"画像增量更新堆积时间"
,
str
(
batchTime_beijing
),
str
(
batch
[
'totalDelay'
]))
batch
_time_beijing
=
datetime
.
datetime
.
strptime
(
batch_t
ime
,
GMT_FORMAT
)
+
datetime
.
timedelta
(
hours
=
8
)
send_email
(
"画像增量更新堆积时间"
,
+
"堆积时刻:"
+
str
(
batch_time_beijing
)
+
"堆积时长:"
+
str
(
batch
[
'totalDelay'
]))
is_email
=
1
f
.
write
(
'
%
s
\n
'
%
batch
)
time
.
sleep
(
1800
)
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