From c8902016a4346f09ee0266144500edf0708fc9d7 Mon Sep 17 00:00:00 2001 From: hyeonda02 Date: Sun, 1 Sep 2024 02:08:04 +0900 Subject: [PATCH] =?UTF-8?q?Refactor=20:=20=EC=8A=A4=EC=BC=80=EC=A4=84?= =?UTF-8?q?=EB=9F=AC=20=EC=BD=94=EB=93=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/hsu/umc/server/service/SchedulerServiceImpl.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/hsu/umc/server/service/SchedulerServiceImpl.java b/src/main/java/hsu/umc/server/service/SchedulerServiceImpl.java index b1101f1..649dbf1 100644 --- a/src/main/java/hsu/umc/server/service/SchedulerServiceImpl.java +++ b/src/main/java/hsu/umc/server/service/SchedulerServiceImpl.java @@ -23,7 +23,7 @@ public class SchedulerServiceImpl implements SchedulerService{ private final PhotoRepository photoRepository; private final UuidRepository uuidRepository; private final AmazonS3Manager s3Manager; - @Scheduled(cron = "0 0/1 * * * ?", zone = "Asia/Seoul") + @Scheduled(cron = "0 0 6 * * ?", zone = "Asia/Seoul") @Transactional public void deletePhoto() { log.info("Scheduled task started for deleting photos"); @@ -41,7 +41,7 @@ public void deletePhoto() { uuidRepository.delete(uuid); }); } - private String extractUuidFromPhotoUrl(String photoUrl){ + public String extractUuidFromPhotoUrl(String photoUrl){ String[] parts = photoUrl.split("/"); String uuid = parts[parts.length-1]; System.out.println(uuid);