From 9e845ac2c9d8041868f28dd6a5837e5fcaf35fdf Mon Sep 17 00:00:00 2001 From: strongmhk Date: Thu, 22 Aug 2024 13:28:44 +0900 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20[#97]=20feature:=20health-check=20a?= =?UTF-8?q?pi=20=EA=B5=AC=ED=98=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/gaji/service/config/SecurityConfig.java | 2 +- .../service/domain/test/HealCheckController.java | 14 ++++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 src/main/java/gaji/service/domain/test/HealCheckController.java diff --git a/src/main/java/gaji/service/config/SecurityConfig.java b/src/main/java/gaji/service/config/SecurityConfig.java index 90d59880..3c42d099 100644 --- a/src/main/java/gaji/service/config/SecurityConfig.java +++ b/src/main/java/gaji/service/config/SecurityConfig.java @@ -38,7 +38,7 @@ public class SecurityConfig { private static final String[] AUTH_WHITELIST = { "/oauth2/**", "/swagger-ui/**", "/api-docs", "/swagger-ui-custom.html", "/v3/api-docs/**", "/api-docs/**", "/swagger-ui.html", "/reissue", "/", "/my", - "/api/**", "/api/vote/**" + "/api/**", "/api/vote/**", "/health-check" }; @Bean diff --git a/src/main/java/gaji/service/domain/test/HealCheckController.java b/src/main/java/gaji/service/domain/test/HealCheckController.java new file mode 100644 index 00000000..131eefd3 --- /dev/null +++ b/src/main/java/gaji/service/domain/test/HealCheckController.java @@ -0,0 +1,14 @@ +package gaji.service.domain.test; + +import gaji.service.global.base.BaseResponse; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RestController; + +@RestController +public class HealCheckController { + + @GetMapping("/health-check") + public BaseResponse healthCheck() { + return BaseResponse.onSuccess(null); + } +}