List<Tuple> 참조 해제 적용하기
This commit is contained in:
@@ -155,7 +155,8 @@ public class InferenceResultApiController {
|
|||||||
// @Content(
|
// @Content(
|
||||||
// mediaType = "application/json",
|
// mediaType = "application/json",
|
||||||
// schema =
|
// schema =
|
||||||
// @Schema(implementation = LearningModelResultDto.ProcessResponse.class))),
|
// @Schema(implementation =
|
||||||
|
// LearningModelResultDto.ProcessResponse.class))),
|
||||||
// @ApiResponse(responseCode = "400", description = "잘못된 요청", content = @Content),
|
// @ApiResponse(responseCode = "400", description = "잘못된 요청", content = @Content),
|
||||||
// @ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
// @ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
||||||
// })
|
// })
|
||||||
@@ -197,7 +198,8 @@ public class InferenceResultApiController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// @Operation(summary = "학습모델 결과 일괄 처리", description = "여러 학습모델 GeoJSON 파일을 일괄 처리하여 데이터베이스에 저장합니다.")
|
// @Operation(summary = "학습모델 결과 일괄 처리", description = "여러 학습모델 GeoJSON 파일을 일괄 처리하여 데이터베이스에
|
||||||
|
// 저장합니다.")
|
||||||
// @ApiResponses(
|
// @ApiResponses(
|
||||||
// value = {
|
// value = {
|
||||||
// @ApiResponse(
|
// @ApiResponse(
|
||||||
@@ -208,7 +210,8 @@ public class InferenceResultApiController {
|
|||||||
// mediaType = "application/json",
|
// mediaType = "application/json",
|
||||||
// schema =
|
// schema =
|
||||||
// @Schema(
|
// @Schema(
|
||||||
// implementation = LearningModelResultDto.BatchProcessResponse.class))),
|
// implementation =
|
||||||
|
// LearningModelResultDto.BatchProcessResponse.class))),
|
||||||
// @ApiResponse(responseCode = "400", description = "잘못된 요청", content = @Content),
|
// @ApiResponse(responseCode = "400", description = "잘못된 요청", content = @Content),
|
||||||
// @ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
// @ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
||||||
// })
|
// })
|
||||||
@@ -269,7 +272,8 @@ public class InferenceResultApiController {
|
|||||||
// mediaType = "application/json",
|
// mediaType = "application/json",
|
||||||
// schema =
|
// schema =
|
||||||
// @Schema(
|
// @Schema(
|
||||||
// implementation = LearningModelResultDto.BatchProcessResponse.class))),
|
// implementation =
|
||||||
|
// LearningModelResultDto.BatchProcessResponse.class))),
|
||||||
// @ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
// @ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
||||||
// })
|
// })
|
||||||
// @PostMapping("/learning-model/process-default")
|
// @PostMapping("/learning-model/process-default")
|
||||||
|
|||||||
@@ -171,6 +171,9 @@ public class ChangeDetectionRepositoryImpl extends QuerydslRepositorySupport
|
|||||||
ChangeDetectionDto.PolygonFeatureList polygonList = new ChangeDetectionDto.PolygonFeatureList();
|
ChangeDetectionDto.PolygonFeatureList polygonList = new ChangeDetectionDto.PolygonFeatureList();
|
||||||
polygonList.setType("FeatureCollection");
|
polygonList.setType("FeatureCollection");
|
||||||
polygonList.setFeatures(result);
|
polygonList.setFeatures(result);
|
||||||
|
|
||||||
|
list.clear(); // List<Tuple> 사용 참조 해제
|
||||||
|
|
||||||
return polygonList;
|
return polygonList;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -194,7 +197,8 @@ public class ChangeDetectionRepositoryImpl extends QuerydslRepositorySupport
|
|||||||
.fetch();
|
.fetch();
|
||||||
|
|
||||||
GeoJsonReader reader = new GeoJsonReader();
|
GeoJsonReader reader = new GeoJsonReader();
|
||||||
return list.stream()
|
List<ChangeDetectionDto.PointFeature> result =
|
||||||
|
list.stream()
|
||||||
.map(
|
.map(
|
||||||
tuple -> {
|
tuple -> {
|
||||||
String geojson = tuple.get(0, String.class);
|
String geojson = tuple.get(0, String.class);
|
||||||
@@ -213,6 +217,10 @@ public class ChangeDetectionRepositoryImpl extends QuerydslRepositorySupport
|
|||||||
"Feature", geom, new ChangeDetectionDto.PointProperties(geoUid, classCd));
|
"Feature", geom, new ChangeDetectionDto.PointProperties(geoUid, classCd));
|
||||||
})
|
})
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
|
list.clear(); // List<Tuple> 사용 참조 해제
|
||||||
|
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user