Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
熊鹏飞
/
xxljob220
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
d0e8674f
authored
Feb 22, 2019
by
许雪里
Committed by
GitHub
Feb 22, 2019
Browse files
Options
_('Browse Files')
Download
Plain Diff
Merge pull request #607 from jiangeeq/master
调用destroy方法的时候,jobHandlerRepository也要清空
parents
32a84353
1b90a9ca
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
xxl-job-core/src/main/java/com/xxl/job/core/executor/XxlJobExecutor.java
xxl-job-core/src/main/java/com/xxl/job/core/executor/XxlJobExecutor.java
View file @
d0e8674f
...
@@ -92,6 +92,12 @@ public class XxlJobExecutor {
...
@@ -92,6 +92,12 @@ public class XxlJobExecutor {
}
}
jobThreadRepository
.
clear
();
jobThreadRepository
.
clear
();
}
}
if
(
jobHandlerRepository
.
size
()
>
0
){
for
(
Map
.
Entry
<
String
,
IJobHandler
>
item:
jobHandlerRepository
.
entrySet
()){
removeJobHandler
(
item
.
getKey
(),
"web container destroy and kill the jod handler"
);
}
jobHandlerRepository
.
clear
();
}
// destory JobLogFileCleanThread
// destory JobLogFileCleanThread
...
@@ -104,6 +110,13 @@ public class XxlJobExecutor {
...
@@ -104,6 +110,13 @@ public class XxlJobExecutor {
stopRpcProvider
();
stopRpcProvider
();
}
}
private
void
removeJobHandler
(
String
handlerId
,
String
removeOldReason
){
IJobHandler
oldJobHandler
=
jobHandlerRepository
.
remove
(
handlerId
);
if
(
oldJobHandler
!=
null
)
{
oldJobHandler
.
destroy
();
}
}
// ---------------------- admin-client (rpc invoker) ----------------------
// ---------------------- admin-client (rpc invoker) ----------------------
private
static
List
<
AdminBiz
>
adminBizList
;
private
static
List
<
AdminBiz
>
adminBizList
;
...
...
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