This module provides query logging for
- Spring Cloud Gateway
- Spring WebFlux WebClient
To use this lid, just add it as dependency
```
dependencies {
...
implementation("io.github.breninsul:webflux-logging:${verison}")
...
}
```
Properties (can bes set from system env or application properties)
Spring Cloud Gateway:
Property | Default | Description |
---|---|---|
webflux.logging.gateway.max-body-size | 10000 | Maximum body size to log |
webflux.logging.gateway.add-id-header | TRUE | Add request id to response header |
webflux.logging.gateway.log-time | TRUE | Log the elapsed time from the request to the response |
webflux.logging.gateway.log-headers | TRUE | Log headers |
webflux.logging.gateway.log-body | TRUE | Log body |
webflux.logging.gateway.level | INFO | Level for logging messages |
webflux.logging.gateway.logger | io.github.breninsul.webfluxlogging.cloud.SpringCloudGatewayLoggingFilter | Class for logger |
webflux.logging.gateway.disabled | FALSE | Disable autoconfiguration (register Filter as bean) Spring Cloud Gateway logging filter |
Spring WebFlux WebClient:
Property | Default | Description |
---|---|---|
webflux.logging.webclient.max-body-size.web_client | 10000 | Maximum body size to log |
webflux.logging.webclient.log-time.web_client | TRUE | Log the elapsed time from the request to the response |
webflux.logging.webclient.log-headers.web_client | TRUE | Log headers |
webflux.logging.webclient.log-body.web_client | TRUE | Log body |
webflux.logging.webclient.level | INFO | Level for logging messages |
webflux.logging.webclient.logger | org.springframework.web.reactive.function.client.WebClient | Class for logger |
webflux.logging.webclient.disabled | FALSE | Disable autoconfiguration (register WebClient with logging filter as bean) Spring WebClient filter |