[#18] 코드 정리 및 일부 컨벤션 통일 #19

Merged
pricelees merged 24 commits from refactor/#18 into main 2025-07-22 09:05:31 +00:00
Showing only changes of commit dceae0bfda - Show all commits

View File

@ -26,15 +26,6 @@ class ExceptionControllerAdvice(
.body(CommonErrorResponse(e.errorType)) .body(CommonErrorResponse(e.errorType))
} }
@ExceptionHandler(ResourceAccessException::class)
fun handleResourceAccessException(e: ResourceAccessException): ResponseEntity<CommonErrorResponse> {
logger.error(e) { "message: ${e.message}" }
return ResponseEntity
.status(HttpStatus.INTERNAL_SERVER_ERROR)
.body(CommonErrorResponse(ErrorType.PAYMENT_SERVER_ERROR))
}
@ExceptionHandler(value = [HttpMessageNotReadableException::class]) @ExceptionHandler(value = [HttpMessageNotReadableException::class])
fun handleHttpMessageNotReadableException(e: HttpMessageNotReadableException): ResponseEntity<CommonErrorResponse> { fun handleHttpMessageNotReadableException(e: HttpMessageNotReadableException): ResponseEntity<CommonErrorResponse> {
logger.error(e) { "message: ${e.message}" } logger.error(e) { "message: ${e.message}" }
@ -56,15 +47,6 @@ class ExceptionControllerAdvice(
.body(CommonErrorResponse(ErrorType.INVALID_REQUEST_DATA, messages)) .body(CommonErrorResponse(ErrorType.INVALID_REQUEST_DATA, messages))
} }
@ExceptionHandler(value = [HttpRequestMethodNotSupportedException::class])
fun handleHttpRequestMethodNotSupportedException(e: HttpRequestMethodNotSupportedException): ResponseEntity<CommonErrorResponse> {
logger.error(e) { "message: ${e.message}" }
return ResponseEntity
.status(HttpStatus.METHOD_NOT_ALLOWED)
.body(CommonErrorResponse(ErrorType.METHOD_NOT_ALLOWED))
}
@ExceptionHandler(value = [Exception::class]) @ExceptionHandler(value = [Exception::class])
fun handleException(e: Exception): ResponseEntity<CommonErrorResponse> { fun handleException(e: Exception): ResponseEntity<CommonErrorResponse> {
logger.error(e) { "message: ${e.message}" } logger.error(e) { "message: ${e.message}" }