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
321640e9
Commit
321640e9
authored
Dec 09, 2020
by
huangfusuper
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
异步实例保护
parent
29ede9b7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
+7
-0
ApiFlowServiceImpl.java
...c/main/java/com/byit/service/impl/ApiFlowServiceImpl.java
+4
-0
RpcCallbackInstanceRunTheLifeCycleCallback.java
...tegy/impl/RpcCallbackInstanceRunTheLifeCycleCallback.java
+3
-0
No files found.
byit-myth-admin/src/main/java/com/byit/service/impl/ApiFlowServiceImpl.java
View file @
321640e9
...
...
@@ -14,6 +14,7 @@ import com.byit.dto.specials.RepairFlow;
import
com.byit.dto.specials.RepairTimeParam
;
import
com.byit.enums.*
;
import
com.byit.enums.plugin.PluginNodeTypeEnum
;
import
com.byit.enums.task.RunResultEnum
;
import
com.byit.job.utils.CronExpression
;
import
com.byit.job.utils.CurrentUserUtils
;
import
com.byit.job.utils.PlaceholderUtils
;
...
...
@@ -1668,6 +1669,9 @@ public class ApiFlowServiceImpl implements ApiFlowService {
StringBuffer
runids
=
new
StringBuffer
();
//暂停工作流调度
recordingList
.
forEach
(
runRecording
->
{
if
(
RunRecordingEnum
.
FLOW_STATUS_IS_END
.
getCode
().
equals
(
runRecording
.
getFlowStatus
())){
throw
new
RuntimeException
(
String
.
format
(
"实例%s是完结状态"
,
runRecording
.
getFlowName
()));
}
//runRecordingMapper.stopByRunIdAndFlowId(runRecording.getRunId(), runRecording.getFlowId());
runRecordingMapper
.
stopByRunIdAndFlowId
(
runRecording
.
getRunId
(),
runRecording
.
getFlowId
());
jobTaskMapper
.
stopByRunIdAndFlowId
(
runRecording
.
getRunId
(),
runRecording
.
getFlowId
());
...
...
byit-myth-core/myth-admin-core/src/main/java/com/byit/strategy/impl/RpcCallbackInstanceRunTheLifeCycleCallback.java
View file @
321640e9
...
...
@@ -71,6 +71,9 @@ public class RpcCallbackInstanceRunTheLifeCycleCallback implements InstanceRunTh
CallbackDto
callbackDto
=
new
CallbackDto
();
PluginRpcRequestPacket
param
=
buildPluginRpcRequestPacket
(
runRecording
,
callbackDto
,
rpcServerKey
);
PluginRpcResponsePacket
call
=
taskServer
.
call
(
param
);
if
(!
call
.
isStatus
())
{
throw
new
RuntimeException
(
call
.
getMsg
());
}
Object
result
=
call
.
getResult
();
ReturnResult
<
String
>
returnResult
=
(
ReturnResult
<
String
>)
result
;
ScriptParamAndPlaceholderDto
rpcScriptParamAndPlaceholderDto
=
JSON
.
parseObject
(
returnResult
.
getContent
(),
ScriptParamAndPlaceholderDto
.
class
);
...
...
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