作者 朱兆平

技术回执处理不转发技术回执到转发目录

... ... @@ -44,6 +44,10 @@ public class CustomXmlHandleThread implements Runnable{
@Value("${custom.errBakDir}")
private String errBakDir;
//回执转发目录
@Value("${custom.transmitDir}")
private String transmitDir;
//匹配技术回执正则
@Value("${custom.delTechnologyReceptMatch}")
private String delTechnologyReceptMatch;
... ... @@ -94,6 +98,8 @@ public class CustomXmlHandleThread implements Runnable{
customXmlHandle.delTechnologyReceptMatch = this.delTechnologyReceptMatch;
customXmlHandle.transmitDir = this.transmitDir;
// 初使化时将已静态化的testService实例化
}
... ... @@ -109,6 +115,8 @@ public class CustomXmlHandleThread implements Runnable{
else
{
try{
//解析前先转发
FileUtils.copyFileToDirectory(xmlfile, new File(customXmlHandle.transmitDir));
int i =handelXmlDocument();
String today = DateUtil.getTodayBy_yyyyMMdd();
String backdireByDay = customXmlHandle.bakupDir + "/" + today;
... ...
... ... @@ -108,13 +108,10 @@ public class TaskAnalysis {
private void threadJbob(File file,CountDownLatch latch,String transToCfps,ThreadPoolExecutor threadPool){
try{
FileUtils.copyFileToDirectory(file, new File(transToCfps));
CustomXmlHandleThread customXmlHandleThread = new CustomXmlHandleThread();
customXmlHandleThread.setXmlfile(file);
customXmlHandleThread.setLatch(latch);
threadPool.execute(customXmlHandleThread);
}catch (IOException e){
log.error("备份文件{}出错,错误代码:{}",file,e);
}catch (Exception e){
log.error("线程解析出错{}",e);
}
... ...