-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feat/275] api 요청 로그 filter 구현 및 로그인 요청 로그 출력 추가 #276
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
정말 고생 많으셨습니다ㅜㅜ!
} catch (Exception e) { | ||
log.error("LoggerAspect error", e); | ||
// requestId가 없을 경우 기본값 설정 | ||
String requestId = (String) MDC.get("requestId"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오 혹시 이 requestId는 무엇인가요..? 이 메소드가 무슨 일을 하는지 궁금한데 알려주실 수 있으신가요..?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
한번에 여러 요청이 들어오면 로그가 req, res 한 쌍으로 연속해서 출력되지 않고 req req req res res res 이런식으로 출력되는데,, MDC를 사용하면 매 요청별로 고유의 아이디 값을 저장할 수 있다고 하더라구요..! 요청 - 응답 쌍을 더 구분하기 쉽게 하고 싶어서 추가했습니다!
filterChain.doFilter(request, response); | ||
|
||
// 응답 정보 추출 | ||
// long executionTime = System.currentTimeMillis() - startTime; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
지우지 않고 주석으로 남겨둔 이유가 궁금합니당..!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
앗 혹시 나중에 시간 정보 출력이 필요할까봐 놔두긴 했는데,, 그냥 지우는게 나을 것 같아요 ! 수정하고 머지하겠습니다!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
앗 아니 수정하고 머지하겠다고 해놓고 바로 머지를 눌러버렸어요....... 다음 pr에서 수정하겠습니다 ㅠㅠ
🚀 개요
api 요청 로그 filter 구현
로그인 요청 로그 출력 추가
🔍 변경사항
⏳ 작업 내용
📝 논의사항