Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
byit-myth-job
Overview
Overview
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liyuan
byit-myth-job
Commits
0a09a27e
Commit
0a09a27e
authored
Apr 30, 2020
by
guo_minglei@163.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改统计方法
parent
0a61b194
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
StatusSnapshootThreadRunHelper.java
...om/byit/thread/helper/StatusSnapshootThreadRunHelper.java
+9
-2
No files found.
byit-myth-core/myth-admin-core/src/main/java/com/byit/thread/helper/StatusSnapshootThreadRunHelper.java
View file @
0a09a27e
...
@@ -96,7 +96,7 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
...
@@ -96,7 +96,7 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
//判断运行状态
//判断运行状态
if
(
runRecording
.
getFlowStatus
().
equals
(
"1"
)
||
runRecording
.
getFlowStatus
().
equals
(
"2"
)
||
runRecording
.
getFlowStatus
().
equals
(
"3"
)){
if
(
runRecording
.
getFlowStatus
().
equals
(
"1"
)
||
runRecording
.
getFlowStatus
().
equals
(
"2"
)
||
runRecording
.
getFlowStatus
().
equals
(
"3"
)){
hourFlowStatusSnapshoot
.
setFlowStatus
(
Integer
.
valueOf
(
runRecording
.
getFlowStatus
()));
hourFlowStatusSnapshoot
.
setFlowStatus
(
Integer
.
valueOf
(
runRecording
.
getFlowStatus
()));
}
else
{
}
else
if
(
runRecording
.
getFlowStatus
().
equals
(
"4"
))
{
switch
(
runRecording
.
getFlowRunResult
()){
switch
(
runRecording
.
getFlowRunResult
()){
case
"1"
:
case
"1"
:
case
"3"
:
hourFlowStatusSnapshoot
.
setFlowStatus
(
4
);
break
;
case
"3"
:
hourFlowStatusSnapshoot
.
setFlowStatus
(
4
);
break
;
...
@@ -105,6 +105,9 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
...
@@ -105,6 +105,9 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
case
"5"
:
hourFlowStatusSnapshoot
.
setFlowStatus
(
6
);
break
;
case
"5"
:
hourFlowStatusSnapshoot
.
setFlowStatus
(
6
);
break
;
default
:
hourFlowStatusSnapshoot
.
setFlowStatus
(
5
);
break
;
default
:
hourFlowStatusSnapshoot
.
setFlowStatus
(
5
);
break
;
}
}
}
else
{
//如果没在判断之内,设置为未运行
hourFlowStatusSnapshoot
.
setFlowStatus
(
1
);
}
}
//获取运行实例下各类状态的节点数目
//获取运行实例下各类状态的节点数目
StatisticData
nodeStatistic
=
jobTaskRunLogMapper
.
findStatisticDataByRunIdAndFlowId
(
runRecording
.
getRunId
(),
flow
.
getFlowId
());
StatisticData
nodeStatistic
=
jobTaskRunLogMapper
.
findStatisticDataByRunIdAndFlowId
(
runRecording
.
getRunId
(),
flow
.
getFlowId
());
...
@@ -112,7 +115,11 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
...
@@ -112,7 +115,11 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
//存在节点运行日志
//存在节点运行日志
if
(
nodeStatistic
!=
null
){
if
(
nodeStatistic
!=
null
){
int
sum
=
nodeStatistic
.
getFail
()
+
nodeStatistic
.
getSuccess
()
+
nodeStatistic
.
getRunIng
()
+
nodeStatistic
.
getKill
();
int
sum
=
nodeStatistic
.
getFail
()
+
nodeStatistic
.
getSuccess
()
+
nodeStatistic
.
getRunIng
()
+
nodeStatistic
.
getKill
();
hourFlowStatusSnapshoot
.
setUnstartNode
(
flow
.
getFlowNodeCount
()
-
sum
);
if
(
flow
.
getFlowNodeCount
()
>
sum
){
hourFlowStatusSnapshoot
.
setUnstartNode
(
flow
.
getFlowNodeCount
()
-
sum
);
}
else
{
hourFlowStatusSnapshoot
.
setUnstartNode
(
0
);
}
hourFlowStatusSnapshoot
.
setRuningNode
(
nodeStatistic
.
getRunIng
());
hourFlowStatusSnapshoot
.
setRuningNode
(
nodeStatistic
.
getRunIng
());
hourFlowStatusSnapshoot
.
setSuccessNode
(
nodeStatistic
.
getSuccess
());
hourFlowStatusSnapshoot
.
setSuccessNode
(
nodeStatistic
.
getSuccess
());
hourFlowStatusSnapshoot
.
setFailNode
(
nodeStatistic
.
getFail
());
hourFlowStatusSnapshoot
.
setFailNode
(
nodeStatistic
.
getFail
());
...
...
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