| | |
| | | if(!logFile.exists() || !logFile.isFile()){ |
| | | throw new VciBaseException("本地日志文件路径"+item.getPath()+"中未找到日志"); |
| | | } |
| | | |
| | | try(OutputStream os = new FileOutputStream(file); |
| | | InputStream ins = new FileInputStream(logFile); |
| | | ){ |
| | |
| | | String zipName = new File(tempFolder).getPath() + File.separator + getLogFileName(logFullPaths) + "等"+file1.length + "个文件.zip"; |
| | | zipUtil.folderToZipFile(tempFolder,zipName); |
| | | fileObjectBO.setFileLocalPath(zipName); |
| | | fileObjectBO.setName(zipName); |
| | | fileObjectBO.setFileExtension(".log"); |
| | | if(log.isDebugEnabled()){ |
| | | log.debug("下载文件的信息,",zipName); |
| | | } |
| | | }else{ |
| | | throw new ServerException("该目录下不存在日志文件!"); |
| | | } |
| | | } |
| | | return fileObjectBO; |