Merge pull request '추론 실행 수정' (#237) from feat/infer_dev_260107 into develop
Reviewed-on: https://kamco.gitea.gs.dabeeo.com/dabeeo/kamco-dabeeo-backoffice/pulls/237
This commit is contained in:
@@ -516,9 +516,8 @@ public class InferenceResultService {
|
||||
externalHttpClient.call(url, HttpMethod.DELETE, dto, headers, String.class);
|
||||
|
||||
if (!result.success()) {
|
||||
throw new CustomApiException("NOT_FOUND", HttpStatus.NOT_FOUND);
|
||||
log.warn("Failed to delete inference result");
|
||||
}
|
||||
System.out.println(result);
|
||||
|
||||
SaveInferenceAiDto request = new SaveInferenceAiDto();
|
||||
request.setStatus(Status.END.getId());
|
||||
|
||||
@@ -71,6 +71,9 @@ public class MapSheetInferenceJobService {
|
||||
// 추론실행 상태 정보 가져오기
|
||||
JobStatusDto job = fetchJobStatus(batchId);
|
||||
if (job == null) {
|
||||
// TODO END가 아닌 상태의 추론목록이 있고 추론 api 호출할때 404면 end로 상태 업데이트
|
||||
// 학습 상태 종료
|
||||
// end(sheet);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -413,4 +416,17 @@ public class MapSheetInferenceJobService {
|
||||
saveInferenceAiDto.setFailedJobs(dto.getFailedJobs());
|
||||
inferenceResultCoreService.update(saveInferenceAiDto);
|
||||
}
|
||||
|
||||
/**
|
||||
* 학습 상태 종료 update
|
||||
*
|
||||
* @param dto
|
||||
*/
|
||||
private void end(InferenceBatchSheet dto) {
|
||||
SaveInferenceAiDto request = new SaveInferenceAiDto();
|
||||
request.setStatus(Status.END.getId());
|
||||
request.setUuid(dto.getUuid());
|
||||
request.setUpdateUid(0L);
|
||||
inferenceResultCoreService.update(request);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user