Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xzxt-api-report
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
雷紫添
xzxt-api-report
Commits
e526e2b8
Commit
e526e2b8
authored
Sep 09, 2019
by
雷紫添
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加任务调度类
parent
dc032a5f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
0 deletions
+33
-0
src/main/java/com/founder/task/ScheduleTask.java
+33
-0
No files found.
src/main/java/com/founder/task/ScheduleTask.java
0 → 100644
View file @
e526e2b8
package
com
.
founder
.
task
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.scheduling.annotation.Scheduled
;
import
org.springframework.stereotype.Component
;
import
java.text.SimpleDateFormat
;
import
java.util.Date
;
import
java.util.List
;
@Component
public
class
ScheduleTask
{
private
SimpleDateFormat
format
=
new
SimpleDateFormat
(
"yyyy/MM/dd HH:mm:ss"
);
private
Logger
logger
=
LoggerFactory
.
getLogger
(
ScheduleTask
.
class
);
@Scheduled
(
cron
=
"1 1 1 1/1 * ? "
)
public
void
taskForDictUpdate
(){
logger
.
info
(
"This is a say method!"
+
format
.
format
(
new
Date
()));
xxbsSerevice
();
}
private
void
xxbsSerevice
(){
//1.从表中获取未上报的信息
//2..将从采集平台获取的信息,在发送给公安部
// JSONObject jsonResult= requestByPost("http://api.xz.xz.ga/jccj/xxbs",jccj);
//更新写日志
}
}
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