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
f82b8dab
Commit
f82b8dab
authored
May 09, 2020
by
guominglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改未获取多个
parent
8aea83f2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
RunRecordingMapper.java
...ore/src/main/java/com/byit/mapper/RunRecordingMapper.java
+1
-1
StatusSnapshootThreadRunHelper.java
...om/byit/thread/helper/StatusSnapshootThreadRunHelper.java
+3
-2
No files found.
byit-myth-core/myth-admin-core/src/main/java/com/byit/mapper/RunRecordingMapper.java
View file @
f82b8dab
...
@@ -189,7 +189,7 @@ public interface RunRecordingMapper {
...
@@ -189,7 +189,7 @@ public interface RunRecordingMapper {
@Param
(
"endTime"
)
Date
endTime
,
@Param
(
"endTime"
)
Date
endTime
,
@Param
(
"flowIdList"
)
List
<
Integer
>
flowIdList
);
@Param
(
"flowIdList"
)
List
<
Integer
>
flowIdList
);
RunRecording
findMaxByFlowId
(
@Param
(
"flowId"
)
Integer
flowId
);
List
<
RunRecording
>
findMaxByFlowId
(
@Param
(
"flowId"
)
Integer
flowId
);
/**
/**
* 查询过去一个小时的和未完成的工作流实例
* 查询过去一个小时的和未完成的工作流实例
...
...
byit-myth-core/myth-admin-core/src/main/java/com/byit/thread/helper/StatusSnapshootThreadRunHelper.java
View file @
f82b8dab
...
@@ -66,7 +66,7 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
...
@@ -66,7 +66,7 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
List
<
FlowStatusSnapshoot
>
flowStatusSnapshootList
=
new
ArrayList
<>();
List
<
FlowStatusSnapshoot
>
flowStatusSnapshootList
=
new
ArrayList
<>();
flowList
.
forEach
(
flow
->
{
flowList
.
forEach
(
flow
->
{
RunRecording
maxRunRecording
=
runRecordingMapper
.
findMaxByFlowId
(
flow
.
getFlowId
());
List
<
RunRecording
>
maxRunRecordingList
=
runRecordingMapper
.
findMaxByFlowId
(
flow
.
getFlowId
());
FlowStatusSnapshoot
flowStatusSnapshoot
=
new
FlowStatusSnapshoot
();
FlowStatusSnapshoot
flowStatusSnapshoot
=
new
FlowStatusSnapshoot
();
flowStatusSnapshoot
.
setDay
(
date
);
flowStatusSnapshoot
.
setDay
(
date
);
flowStatusSnapshoot
.
setFlowId
(
flow
.
getFlowId
());
flowStatusSnapshoot
.
setFlowId
(
flow
.
getFlowId
());
...
@@ -77,9 +77,10 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
...
@@ -77,9 +77,10 @@ public class StatusSnapshootThreadRunHelper extends BaseThreadRunHelper {
//统计运行实例的数据
//统计运行实例的数据
//如果存在实例
//如果存在实例
if
(
maxRunRecording
!=
null
){
if
(
null
!=
maxRunRecordingList
&&
maxRunRecordingList
.
size
()
>
0
){
//获取今天凌晨的时间戳
//获取今天凌晨的时间戳
Long
time
=
LocalDate
.
now
().
atStartOfDay
(
ZoneOffset
.
ofHours
(
8
)).
toInstant
().
toEpochMilli
();
Long
time
=
LocalDate
.
now
().
atStartOfDay
(
ZoneOffset
.
ofHours
(
8
)).
toInstant
().
toEpochMilli
();
RunRecording
maxRunRecording
=
maxRunRecordingList
.
get
(
0
);
//从凌晨到现在是否有运行实例
//从凌晨到现在是否有运行实例
if
(
time
.
longValue
()
>
maxRunRecording
.
getTriggerTime
().
longValue
()){
if
(
time
.
longValue
()
>
maxRunRecording
.
getTriggerTime
().
longValue
()){
flowStatusSnapshoot
.
setFlowStatus
(
1
);
flowStatusSnapshoot
.
setFlowStatus
(
1
);
...
...
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