|
|
|
@ -62,18 +62,25 @@ public class RemoveData {
|
|
|
|
|
Map<String, Object> map = new HashMap<String, Object>();
|
|
|
|
|
map.put("sourcePath", sourceFolderName);
|
|
|
|
|
map.put("destPath", destFolderName);
|
|
|
|
|
//请求web
|
|
|
|
|
String rest = ht.sendPost("data/abortCopyData", map);
|
|
|
|
|
if (null == rest || "".equals(rest)) {
|
|
|
|
|
log.error(" --- gluster is disconnect ! \n");
|
|
|
|
|
return 0;
|
|
|
|
|
String rest ="";
|
|
|
|
|
try {
|
|
|
|
|
//请求web
|
|
|
|
|
rest = ht.sendPost("data/abortCopyData", map);
|
|
|
|
|
if (null == rest || "".equals(rest)) {
|
|
|
|
|
log.error(" --- gluster is disconnect ! \n");
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
Gson gs = new Gson();
|
|
|
|
|
PostData data = gs.fromJson(rest, PostData.class);
|
|
|
|
|
// 1 : 成功
|
|
|
|
|
double copyResult = (double) data.getData();
|
|
|
|
|
reslut = (int) copyResult;
|
|
|
|
|
getExcept(data);
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
log.error(rest);
|
|
|
|
|
log.error(e);
|
|
|
|
|
throw new CustomException("请求gfs服务异常 -- data/removeData ", e, rest);
|
|
|
|
|
}
|
|
|
|
|
Gson gs = new Gson();
|
|
|
|
|
PostData data = gs.fromJson(rest, PostData.class);
|
|
|
|
|
// 1 : 成功
|
|
|
|
|
double copyResult = (double) data.getData();
|
|
|
|
|
reslut = (int) copyResult;
|
|
|
|
|
getExcept(data);
|
|
|
|
|
return reslut;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|