shp파일 생성 수정, 미사용 소스 제거
This commit is contained in:
@@ -22,7 +22,8 @@ public class ExternalJarRunner {
|
|||||||
* @param batchIds 배치 아이디
|
* @param batchIds 배치 아이디
|
||||||
* @param inferenceId uid
|
* @param inferenceId uid
|
||||||
* @param mapIds 추론 실행한 도엽 ids
|
* @param mapIds 추론 실행한 도엽 ids
|
||||||
* @param mode <p>MERGED - batch-ids 에 해당하는 **모든 데이터를 하나의 Shapefile로 병합 생성,
|
* @param mode
|
||||||
|
* <p>MERGED - batch-ids 에 해당하는 **모든 데이터를 하나의 Shapefile로 병합 생성,
|
||||||
* <p>MAP_IDS - 명시적으로 전달한 map-ids만 대상으로 Shapefile 생성,
|
* <p>MAP_IDS - 명시적으로 전달한 map-ids만 대상으로 Shapefile 생성,
|
||||||
* <p>RESOLVE - batch-ids 기준으로 **JAR 내부에서 map_ids를 조회**한 뒤 Shapefile 생성
|
* <p>RESOLVE - batch-ids 기준으로 **JAR 내부에서 map_ids를 조회**한 뒤 Shapefile 생성
|
||||||
*/
|
*/
|
||||||
@@ -43,7 +44,6 @@ public class ExternalJarRunner {
|
|||||||
execJar(jarPath, args);
|
execJar(jarPath, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* geoserver 등록
|
* geoserver 등록
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -30,9 +30,7 @@ public class InferenceResultShpService {
|
|||||||
@Value("${file.dataset-dir}")
|
@Value("${file.dataset-dir}")
|
||||||
private String datasetDir;
|
private String datasetDir;
|
||||||
|
|
||||||
/**
|
/** inference_results 테이블을 기준으로 분석 결과 테이블과 도형 테이블을 최신 상태로 반영한다. */
|
||||||
* inference_results 테이블을 기준으로 분석 결과 테이블과 도형 테이블을 최신 상태로 반영한다.
|
|
||||||
*/
|
|
||||||
@Transactional
|
@Transactional
|
||||||
public InferenceResultShpDto.InferenceCntDto saveInferenceResultData(Long id) {
|
public InferenceResultShpDto.InferenceCntDto saveInferenceResultData(Long id) {
|
||||||
return coreService.buildInferenceData(id);
|
return coreService.buildInferenceData(id);
|
||||||
|
|||||||
@@ -58,9 +58,7 @@ public class MapSheetInferenceJobService {
|
|||||||
@Value("${file.dataset-dir}")
|
@Value("${file.dataset-dir}")
|
||||||
private String datasetDir;
|
private String datasetDir;
|
||||||
|
|
||||||
/**
|
/** 추론 진행 배치 1분 60_000 */
|
||||||
* 추론 진행 배치 1분 60_000
|
|
||||||
*/
|
|
||||||
@Scheduled(fixedDelay = 60_000)
|
@Scheduled(fixedDelay = 60_000)
|
||||||
public void runBatch() {
|
public void runBatch() {
|
||||||
if (isLocalProfile()) {
|
if (isLocalProfile()) {
|
||||||
@@ -427,8 +425,7 @@ public class MapSheetInferenceJobService {
|
|||||||
// 4) 응답 파싱
|
// 4) 응답 파싱
|
||||||
try {
|
try {
|
||||||
List<Map<String, Object>> list =
|
List<Map<String, Object>> list =
|
||||||
objectMapper.readValue(result.body(), new TypeReference<>() {
|
objectMapper.readValue(result.body(), new TypeReference<>() {});
|
||||||
});
|
|
||||||
|
|
||||||
if (list.isEmpty()) {
|
if (list.isEmpty()) {
|
||||||
throw new IllegalStateException("Inference response is empty");
|
throw new IllegalStateException("Inference response is empty");
|
||||||
@@ -456,9 +453,7 @@ public class MapSheetInferenceJobService {
|
|||||||
return "local".equalsIgnoreCase(profile);
|
return "local".equalsIgnoreCase(profile);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/** 모델별 추론 종료 update */
|
||||||
* 모델별 추론 종료 update
|
|
||||||
*/
|
|
||||||
private void updateProcessingEndTimeByModel(
|
private void updateProcessingEndTimeByModel(
|
||||||
BatchStatusDto dto, UUID uuid, ZonedDateTime dateTime, String type) {
|
BatchStatusDto dto, UUID uuid, ZonedDateTime dateTime, String type) {
|
||||||
SaveInferenceAiDto saveInferenceAiDto = new SaveInferenceAiDto();
|
SaveInferenceAiDto saveInferenceAiDto = new SaveInferenceAiDto();
|
||||||
|
|||||||
@@ -16,8 +16,7 @@ public class ShpPipelineService {
|
|||||||
private final ShpKeyLock shpKeyLock;
|
private final ShpKeyLock shpKeyLock;
|
||||||
|
|
||||||
@Async("shpExecutor")
|
@Async("shpExecutor")
|
||||||
public void runPipeline(
|
public void runPipeline(String jarPath, String datasetDir, String batchId, String inferenceId) {
|
||||||
String jarPath, String datasetDir, String batchId, String inferenceId) {
|
|
||||||
|
|
||||||
// inferenceId 기준 동시 실행 제한
|
// inferenceId 기준 동시 실행 제한
|
||||||
if (!shpKeyLock.tryLock(inferenceId)) {
|
if (!shpKeyLock.tryLock(inferenceId)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user