Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart_gov_platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
smart_gov_platform
Commits
19a1e437
Commit
19a1e437
authored
Apr 18, 2023
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加工作人员最后登录时间
parent
a6987451
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
smart-gateway/src/main/java/com/mortals/xhx/base/framework/filter/AccessLogFilter.java
...om/mortals/xhx/base/framework/filter/AccessLogFilter.java
+2
-0
smart-gateway/src/main/resources/bootstrap.yml
smart-gateway/src/main/resources/bootstrap.yml
+3
-2
No files found.
smart-gateway/src/main/java/com/mortals/xhx/base/framework/filter/AccessLogFilter.java
View file @
19a1e437
...
@@ -158,6 +158,7 @@ public class AccessLogFilter implements GlobalFilter, Ordered {
...
@@ -158,6 +158,7 @@ public class AccessLogFilter implements GlobalFilter, Ordered {
log
.
info
(
"decoratedRequest 000"
);
log
.
info
(
"decoratedRequest 000"
);
Mono
<
String
>
modifiedBody
=
serverRequest
.
bodyToMono
(
String
.
class
)
Mono
<
String
>
modifiedBody
=
serverRequest
.
bodyToMono
(
String
.
class
)
.
flatMap
(
body
->
{
.
flatMap
(
body
->
{
log
.
info
(
"decoratedRequest 0001111"
);
accessLogPdu
.
setRequestData
(
body
);
accessLogPdu
.
setRequestData
(
body
);
return
Mono
.
just
(
body
);
return
Mono
.
just
(
body
);
});
});
...
@@ -173,6 +174,7 @@ public class AccessLogFilter implements GlobalFilter, Ordered {
...
@@ -173,6 +174,7 @@ public class AccessLogFilter implements GlobalFilter, Ordered {
return
bodyInserter
.
insert
(
outputMessage
,
new
BodyInserterContext
())
return
bodyInserter
.
insert
(
outputMessage
,
new
BodyInserterContext
())
.
then
(
Mono
.
defer
(()
->
{
.
then
(
Mono
.
defer
(()
->
{
// 重新封装请求
// 重新封装请求
Flux
<
DataBuffer
>
dataBuffers
=
Flux
.
from
(
outputMessage
.
getBody
());
log
.
info
(
"decoratedRequest 1"
);
log
.
info
(
"decoratedRequest 1"
);
ServerHttpRequest
decoratedRequest
=
requestDecorate
(
exchange
,
headers
,
outputMessage
);
ServerHttpRequest
decoratedRequest
=
requestDecorate
(
exchange
,
headers
,
outputMessage
);
// 记录响应日志
// 记录响应日志
...
...
smart-gateway/src/main/resources/bootstrap.yml
View file @
19a1e437
...
@@ -2,8 +2,9 @@ server:
...
@@ -2,8 +2,9 @@ server:
tomcat
:
tomcat
:
uri-encoding
:
utf-8
uri-encoding
:
utf-8
spring
:
spring
:
codec
:
webflux
:
max-in-memory-size
:
50MB
client
:
max-buffer-size
:
1024*1024*20
main
:
main
:
web-application-type
:
reactive
web-application-type
:
reactive
allow-bean-definition-overriding
:
true
allow-bean-definition-overriding
:
true
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment