diff --git a/server/src/main/java/server/haengdong/exception/GlobalExceptionHandler.java b/server/src/main/java/server/haengdong/exception/GlobalExceptionHandler.java index ec8e4cba0..0cee7cb4c 100644 --- a/server/src/main/java/server/haengdong/exception/GlobalExceptionHandler.java +++ b/server/src/main/java/server/haengdong/exception/GlobalExceptionHandler.java @@ -19,11 +19,11 @@ public class GlobalExceptionHandler { private static final String LOG_FORMAT = """ - { + \n\t{ "RequestURI": "{} {}", - "RequestBody": "{}", + "RequestBody": {}, "ErrorMessage": "{}" - } + \t} """; @ExceptionHandler(AuthenticationException.class) @@ -81,7 +81,7 @@ public ResponseEntity handleException(HttpServletRequest req, Exc private String getRequestBody(HttpServletRequest req) { try (BufferedReader reader = req.getReader()) { - return reader.lines().collect(Collectors.joining(System.lineSeparator())); + return reader.lines().collect(Collectors.joining(System.lineSeparator() + "\t")); } catch (IOException e) { log.error("Failed to read request body", e); return "";