Commit 14017361 authored by fangxinjiang's avatar fangxinjiang

上传附件日志清理-fxj

parent d37ebcce
......@@ -64,7 +64,6 @@ public class FileUploadController {
})*/
@PostMapping(value = "/ossUploadFile")
public R<T> uploadImg(@RequestBody MultipartFile file, String filePath, Integer type, String domain) throws IOException {
//return fileUploadService.uploadImg(file,filePath,type,domain);
return fileUploadService.uploadAsso(file,filePath,type,domain,CommonConstants.ZERO_STRING);
}
......@@ -83,7 +82,6 @@ public class FileUploadController {
"\t")
@PostMapping(value = "/uploadFileReturnAtta")
public R<T> uploadFileReturnAtta(@RequestBody MultipartFile file, String filePath, Integer type, String domainId) throws IOException {
//return fileUploadService.uploadFileReturnAtta(file,filePath,type,domainId);
return fileUploadService.uploadAsso(file,filePath,type,domainId,CommonConstants.ONE_STRING);
}
......
......@@ -264,7 +264,6 @@ public class FileUploadServiceImpl implements FileUploadService {
maxLimit = configLimitMapper.getSysConfigLimitByKey("UPLOAD_MAX_LIMIT");
if (atomicInteger.incrementAndGet() <= maxLimit){
try {
log.error("atomicInteger+1:"+atomicInteger.intValue());
if (CommonConstants.ZERO_STRING.equals(uploadType)){
return uploadImg(file, filePath, type, domain);
}else if (CommonConstants.ONE_STRING.equals(uploadType)){
......@@ -274,11 +273,9 @@ public class FileUploadServiceImpl implements FileUploadService {
log.error("附件上传异常:",e);
}finally {
atomicInteger.decrementAndGet();
log.error("atomicInteger-1:"+atomicInteger.intValue());
}
}else {
atomicInteger.decrementAndGet();
log.error("atomicInteger超出阈值-1:"+atomicInteger.intValue());
log.error("超出阈值:"+ResultConstants.FILE_UPLOADING_DATA);
return R.failed(ResultConstants.FILE_UPLOADING_DATA);
}
......
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