Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
bigdatainterservice
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
曹鹏
bigdatainterservice
Commits
77c106a2
Commit
77c106a2
authored
Mar 21, 2019
by
caojingji
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改伴随任务线程中的bug问题
parent
a6cb577a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
10 deletions
+3
-10
src/main/java/com/founder/interservice/tracktraveltogether/service/impl/TogetherScheduledService.java
+3
-10
No files found.
src/main/java/com/founder/interservice/tracktraveltogether/service/impl/TogetherScheduledService.java
View file @
77c106a2
...
...
@@ -58,7 +58,7 @@ public class TogetherScheduledService {
* @Author: cao peng
* @date: 2018/8/22 0022-16:35
*/
@Scheduled
(
initialDelay
=
1
80000
,
fixedDelay
=
18
0000
)
//项目启动后延迟三分钟秒执行,每次执行完后三分钟后再次执行
@Scheduled
(
initialDelay
=
1
20000
,
fixedDelay
=
12
0000
)
//项目启动后延迟三分钟秒执行,每次执行完后三分钟后再次执行
public
void
queryTaskResult
(){
System
.
out
.
println
(
"=============TogetherTask Start Running================"
);
System
.
out
.
println
(
"Thread Name:======="
+
Thread
.
currentThread
().
getName
());
...
...
@@ -87,7 +87,6 @@ public class TogetherScheduledService {
String
info_url
=
TOGETHER_INFO_URL
+
"&taskId="
+
task
.
getTaskId
();
String
taskInfoResult
=
HttpUtil
.
getWaData
(
info_url
);
//String taskInfoResult = "{\"items\":[{\"count\":75,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460013088311061\"},{\"count\":70,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460029233464484\"},{\"count\":65,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460013022609934\"},{\"count\":63,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460013312607010\"},{\"count\":57,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460018669002987\"},{\"count\":53,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460008397079525\"},{\"count\":53,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460020523597601\"},{\"count\":53,\"objectType\":4394,\"objectTypeName\":\"电话号码\",\"objectValue\":\"460003164872839\"}],\"taskId\":\"98f6bcd4621d373cade4e832627b4f6-540-xzxt-api-3-1536231954767\"}";
taskInfoResult
=
HttpUtil
.
getWaData
(
info_url
);
getAndSaveInfo
(
taskInfoResult
,
task
);
}
if
(!
state
.
equals
(
task
.
getState
())){
...
...
@@ -113,14 +112,8 @@ public class TogetherScheduledService {
r
.
setXXZJBH
(
KeyUtil
.
getUniqueKey
(
"TT"
));
r
.
setDjsj
(
new
Date
());
}
TogetherTaskResult
param
=
new
TogetherTaskResult
();
param
.
setTaskId
(
task
.
getTaskId
());
Example
<
TogetherTaskResult
>
example
=
Example
.
of
(
param
);
List
<
TogetherTaskResult
>
results
=
taskResultRepository
.
findAll
(
example
);
if
(
results
==
null
||
results
.
isEmpty
()){
taskResultRepository
.
save
(
taskResults
);
getAndSaveRydetail
(
taskResults
);
}
taskResultRepository
.
save
(
taskResults
);
getAndSaveRydetail
(
taskResults
);
}
}
}
catch
(
Exception
e
){
...
...
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