Skip to content

Commit

Permalink
fix: 로그 간단화 (#161)
Browse files Browse the repository at this point in the history
  • Loading branch information
hyunseung-you authored May 22, 2024
1 parent 799049d commit 4e476a0
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package uoslife.servermeeting.global.config

import org.springframework.context.annotation.Bean
import org.springframework.context.annotation.Configuration
import org.springframework.web.filter.CommonsRequestLoggingFilter

@Configuration
class WebLoggingConfig {

@Bean
fun commonsRequestLoggingFilter(): CommonsRequestLoggingFilter {
val filter = CommonsRequestLoggingFilter()
filter.setIncludeClientInfo(true)
filter.setIncludeHeaders(true)
filter.setHeaderPredicate { header -> header.lowercase() != "authorization" }
filter.setIncludePayload(true)
filter.setIncludeQueryString(true)
filter.setMaxPayloadLength(1000)
return filter
}
}
9 changes: 8 additions & 1 deletion src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ spring:
properties:
hibernate:
default_batch_fetch_size: 1000
show_sql: true
show_sql: false
format_sql: true
flyway:
enabled: true
Expand Down Expand Up @@ -72,3 +72,10 @@ account:
access:
id: ${ACCOUNT_API_ACCESS_ID}
secret: ${ACCOUNT_API_ACCESS_SECRET}

logging:
level:
org:
springframework:
web:
filter: DEBUG

0 comments on commit 4e476a0

Please sign in to comment.