Closed abccbaandy closed 5 years ago
I just supply a simple request log ,you can custom with GlobalFilter
in your own way.
Suggestion:
log-request: false
and read-request-data: true
.GlobalFilter
and Set Order
AfterFilterOrderEnum.GATEWAY_CONTEXT_FILTER.getOrder()
GlobalFilter
, you can custom log with GatewayContext
But set log-request
to false will disable everything, even GatewayContextFilter
, isn't it?
https://github.com/chenggangpro/spring-cloud-gateway-plugin/blob/master/src/main/java/pro/chenggang/plugin/springcloud/gateway/config/GatewayPluginConfig.java
Ops,Temporary you can replace the bean GatewayContextFilter. Later today I’ll fix it.Thx for report.
@abccbaandy I have deploy 1.3.1 to the maven central , You should give it few hours to accept the dependency
Thx for quick fix.
But I'm sorry, I have another question now.
https://github.com/chenggangpro/spring-cloud-gateway-plugin/commit/8cccb2aa964a0b5ea7bb6bb070050c786193d4f5#diff-69f669463220f0e26dc2fc29e2889945R31
According to this commit, I need to update my config to this
spring.cloud.gateway.plugin.grey.enable=true
to enable GatewayContextFilter
But it will also enable those load balancer feature too, which I don't need it.
I was hope there is independent config for GatewayContextFilter
ex: spring.cloud.gateway.plugin.config.enable=true
My deeply apologize. I will fix it indeed.Sorry for that,my bad.
@abccbaandy I just remove @CondtionOnProperties
Config ,Deploy with version 1.3.2.RELEASE.
Sorry for 1.3.1,My Apologize.
In my case, I want log desensitization json instead raw json log.
so I need disable log from
RequestLogFilter
.I try
log-request: false
, but it disable the whole log system.I only need