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
f246cf2f
authored
Jun 06, 2018
by
xuxueli
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
任务线程移除Jetty依赖,为后续RPC模块拆分做准备;
parent
0e4c8c37
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
xxl-job-core/src/main/java/com/xxl/job/core/thread/JobThread.java
xxl-job-core/src/main/java/com/xxl/job/core/thread/JobThread.java
View file @
f246cf2f
...
...
@@ -8,13 +8,15 @@ import com.xxl.job.core.handler.IJobHandler;
import
com.xxl.job.core.log.XxlJobFileAppender
;
import
com.xxl.job.core.log.XxlJobLogger
;
import
com.xxl.job.core.util.ShardingUtil
;
import
org.eclipse.jetty.util.ConcurrentHashSet
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
java.io.PrintWriter
;
import
java.io.StringWriter
;
import
java.util.Collections
;
import
java.util.Date
;
import
java.util.HashSet
;
import
java.util.Set
;
import
java.util.concurrent.LinkedBlockingQueue
;
import
java.util.concurrent.TimeUnit
;
...
...
@@ -28,7 +30,7 @@ public class JobThread extends Thread{
private
int
jobId
;
private
IJobHandler
handler
;
private
LinkedBlockingQueue
<
TriggerParam
>
triggerQueue
;
private
ConcurrentHash
Set
<
Integer
>
triggerLogIdSet
;
// avoid repeat trigger for the same TRIGGER_LOG_ID
private
Set
<
Integer
>
triggerLogIdSet
;
// avoid repeat trigger for the same TRIGGER_LOG_ID
private
volatile
boolean
toStop
=
false
;
private
String
stopReason
;
...
...
@@ -41,7 +43,7 @@ public class JobThread extends Thread{
this
.
jobId
=
jobId
;
this
.
handler
=
handler
;
this
.
triggerQueue
=
new
LinkedBlockingQueue
<
TriggerParam
>();
this
.
triggerLogIdSet
=
new
ConcurrentHashSet
<
Integer
>(
);
this
.
triggerLogIdSet
=
Collections
.
synchronizedSet
(
new
HashSet
<
Integer
>()
);
}
public
IJobHandler
getHandler
()
{
return
handler
;
...
...
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