下载优化
This commit is contained in:
@@ -89,7 +89,7 @@ public class AskDeviceDataServiceImpl implements AskDeviceDataService {
|
||||
|
||||
@Override
|
||||
public boolean downloadFile(String nDid, String name, Integer size, String fileCheck) {
|
||||
boolean result = true;
|
||||
boolean result = false;
|
||||
try {
|
||||
redisUtil.saveByKeyWithExpire("fileDowning:"+nDid,"fileDowning",300L);
|
||||
redisUtil.saveByKeyWithExpire("fileCheck"+name,fileCheck,300L);
|
||||
@@ -104,9 +104,8 @@ public class AskDeviceDataServiceImpl implements AskDeviceDataService {
|
||||
Thread.sleep(2000);
|
||||
Object object2 = redisUtil.getObjectByKey("downloadFilePath:"+name);
|
||||
if (!Objects.isNull(object2)) {
|
||||
result = true;
|
||||
break;
|
||||
} else {
|
||||
result = false;
|
||||
}
|
||||
}
|
||||
mid = mid + 1;
|
||||
|
||||
Reference in New Issue
Block a user