Commit 8646ce66 by 陶光胜

初始化修改

parent 2cad6e78
...@@ -28,6 +28,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -28,6 +28,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.PostConstruct;
import javax.sql.DataSource; import javax.sql.DataSource;
import java.io.*; import java.io.*;
import java.math.BigDecimal; import java.math.BigDecimal;
...@@ -463,6 +464,7 @@ public class FlatQueryResultServiceImpl implements IFlatQueryResultService { ...@@ -463,6 +464,7 @@ public class FlatQueryResultServiceImpl implements IFlatQueryResultService {
} }
@Override @Override
@PostConstruct
public void initTask(){ public void initTask(){
List<DownloadRecord> list = DownloadTaskServiceImpl.getInstance().listUnDownloadTask(QueryDataSource.FLAT_QUERY); List<DownloadRecord> list = DownloadTaskServiceImpl.getInstance().listUnDownloadTask(QueryDataSource.FLAT_QUERY);
if(CollectionUtils.isNotEmpty(list)){ if(CollectionUtils.isNotEmpty(list)){
......
...@@ -26,6 +26,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -26,6 +26,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.PostConstruct;
import java.io.*; import java.io.*;
import java.nio.charset.Charset; import java.nio.charset.Charset;
import java.sql.*; import java.sql.*;
...@@ -313,6 +314,7 @@ public class FreeQueryServiceImpl implements IFreeQueryService { ...@@ -313,6 +314,7 @@ public class FreeQueryServiceImpl implements IFreeQueryService {
@Override @Override
@PostConstruct
public void initTask() { public void initTask() {
List<DownloadRecord> list = DownloadTaskServiceImpl.getInstance().listUnDownloadTask(QueryDataSource.FREE_QUERY); List<DownloadRecord> list = DownloadTaskServiceImpl.getInstance().listUnDownloadTask(QueryDataSource.FREE_QUERY);
if(CollectionUtils.isNotEmpty(list)) { if(CollectionUtils.isNotEmpty(list)) {
......
...@@ -21,8 +21,8 @@ public class MyApplicationContextAware implements ApplicationContextAware { ...@@ -21,8 +21,8 @@ public class MyApplicationContextAware implements ApplicationContextAware {
@Override @Override
public void setApplicationContext(ApplicationContext appContext) throws BeansException { public void setApplicationContext(ApplicationContext appContext) throws BeansException {
this.freeQueryService.initTask(); //this.freeQueryService.initTask();
this.flatQueryResultService.initTask(); //this.flatQueryResultService.initTask();
log.info("任务初始化"); log.info("任务初始化");
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment