feat: add redis
This commit is contained in:
@@ -5,6 +5,7 @@ import com.kamco.cd.kamcoback.changedetection.dto.ChangeDetectionDto;
|
||||
import com.kamco.cd.kamcoback.postgres.core.ChangeDetectionCoreService;
|
||||
import java.util.List;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.cache.annotation.Cacheable;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Service
|
||||
@@ -34,11 +35,14 @@ public class ChangeDetectionService {
|
||||
return changeDetectionCoreService.getChangeDetectionYearList();
|
||||
}
|
||||
|
||||
@Cacheable(value = "changeDetectionPolygon", key = "#analUid + '_' + #mapSheetNum")
|
||||
public ChangeDetectionDto.PolygonFeatureList getChangeDetectionPolygonList(
|
||||
Long analUid, String mapSheetNum) {
|
||||
|
||||
return changeDetectionCoreService.getChangeDetectionPolygonList(analUid, mapSheetNum);
|
||||
}
|
||||
|
||||
// Geometry 객체 순환 참조 문제로 캐싱 불가
|
||||
public ChangeDetectionDto.PointFeatureList getChangeDetectionPointList(
|
||||
Long analUid, String mapSheetNum) {
|
||||
return changeDetectionCoreService.getChangeDetectionPointList(analUid, mapSheetNum);
|
||||
|
||||
Reference in New Issue
Block a user