Skip to content

Commit

Permalink
[fix] GroupController 시큐리티 등록 및 AOP Exception 로그 레벨 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
boo105 committed Feb 11, 2024
1 parent 27b7fd0 commit 2e5bdda
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ protected SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
.requestMatchers(HttpMethod.DELETE, "/**/user").authenticated()
.requestMatchers(HttpMethod.POST, "/**/user/profileImg", "/**/user/nickname").authenticated()
.requestMatchers(HttpMethod.POST, "/**/restaurant/**", "/**/restaurant").authenticated()
.requestMatchers("/**/group/**", "/**/group").authenticated()
.anyRequest().permitAll()

// JwtFilter 를 addFilterBefore 로 등록했던 JwtSecurityConfig 클래스를 적용
Expand Down
6 changes: 5 additions & 1 deletion src/main/java/com/gdsc/jmt/global/logs/LoggingAspect.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,11 @@ public Object printLog(ProceedingJoinPoint joinPoint) throws Throwable {
try {
result = joinPoint.proceed(joinPoint.getArgs());
return result;
} finally {
}
catch (Exception e) {
logger.error("error trace : ", e);
}
finally {
try {
logger.info(getRequestUrl(joinPoint));
logger.info("request : " + objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(params(joinPoint)));
Expand Down

0 comments on commit 2e5bdda

Please sign in to comment.