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
bda71343
Commit
bda71343
authored
Apr 08, 2020
by
guo_minglei@163.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改判断条件
parent
61b1f7f6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
5 deletions
+8
-5
ApiFlowServiceImpl.java
...c/main/java/com/byit/service/impl/ApiFlowServiceImpl.java
+5
-3
StatusSnapshootThreadRunHelper.java
...om/byit/thread/helper/StatusSnapshootThreadRunHelper.java
+3
-2
No files found.
byit-myth-admin/src/main/java/com/byit/service/impl/ApiFlowServiceImpl.java
View file @
bda71343
...
...
@@ -749,15 +749,17 @@ public class ApiFlowServiceImpl implements ApiFlowService {
//如果工作空间下面有数据
if
(
flowIdList
.
size
()
>
0
){
StatisticData
flowStatisticData
=
runRecordingMapper
.
findStatusByStartAndEndTime
(
new
Date
(
startTime
),
new
Date
(
endTime
),
flowIdList
);
if
(
null
!
=
flowStatisticData
){
if
(
null
=
=
flowStatisticData
){
flowStatisticData
=
new
StatisticData
();
flowStatisticData
.
setUnstart
(
flowList
.
size
());
}
StatisticData
nodeStatisticData
=
jobTaskRunLogMapper
.
findStatusByStartAndEndTime
(
new
Date
(
startTime
),
new
Date
(
endTime
),
flowIdList
);
if
(
null
!=
nodeStatisticData
){
List
<
Node
>
nodeList
=
nodeMapper
.
findbyFlowIds
(
flowIdList
);
if
(
null
==
nodeStatisticData
){
nodeStatisticData
=
new
StatisticData
();
List
<
Node
>
nodeList
=
nodeMapper
.
findbyFlowIds
(
flowIdList
);
nodeStatisticData
.
setUnstart
(
nodeList
.
size
());
}
else
{
nodeStatisticData
.
setUnstart
(
nodeList
.
size
()
-
nodeStatisticData
.
getUnstart
());
}
List
<
FlowStatusSnapshoot
>
flowStatusSnapshootList
=
flowStatusSnapshootMapper
.
findByTime
(
startTime
,
endTime
);
...
...
byit-myth-core/myth-admin-core/src/main/java/com/byit/thread/helper/StatusSnapshootThreadRunHelper.java
View file @
bda71343
...
...
@@ -78,11 +78,12 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
if
(
runRecording
!=
null
){
//获取凌晨的时间戳
Long
time
=
LocalDate
.
now
().
atStartOfDay
(
ZoneOffset
.
ofHours
(
8
)).
toInstant
().
toEpochMilli
();
Long
preHourTime
=
hourDateTime
.
minusHours
(
1
).
toInstant
(
ZoneOffset
.
of
(
"+8"
)).
toEpochMilli
();
//从凌晨到现在是否有运行实例
if
(
time
.
longValue
()
>
runRecording
.
getTriggerTime
().
longValue
()){
//今天不存在工作流的运行实例
if
(
preHourTime
.
longValue
()
<
runRecording
.
getTriggerTime
().
longValue
()){
flowStatusSnapshoot
.
setFlowStatus
(
1
);
flowStatusSnapshoot
.
setUnstartNode
(
flow
.
getFlowNodeCount
());
}
else
{
//存在工作流的运行实例
}
else
{
//存在工作流的运行实例
//判断运行状态
if
(
runRecording
.
getFlowStatus
().
equals
(
"1"
)
||
runRecording
.
getFlowStatus
().
equals
(
"2"
)
||
runRecording
.
getFlowStatus
().
equals
(
"3"
)){
flowStatusSnapshoot
.
setFlowStatus
(
Integer
.
valueOf
(
runRecording
.
getFlowStatus
()));
...
...
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