Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
finance-manage
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
finance-oa
finance-manage
Commits
6cf2a8ed
Commit
6cf2a8ed
authored
Dec 16, 2020
by
RuoYi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
升级SpringBoot到最新版本2.2.12 提升启动速度
parent
67198aed
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
6 deletions
+7
-6
pom.xml
pom.xml
+1
-1
ruoyi-common/src/main/java/com/ruoyi/common/filter/RepeatableFilter.java
...c/main/java/com/ruoyi/common/filter/RepeatableFilter.java
+2
-2
ruoyi-common/src/main/java/com/ruoyi/common/filter/XssHttpServletRequestWrapper.java
...com/ruoyi/common/filter/XssHttpServletRequestWrapper.java
+1
-2
ruoyi-framework/src/main/java/com/ruoyi/framework/config/RedisConfig.java
...src/main/java/com/ruoyi/framework/config/RedisConfig.java
+3
-1
No files found.
pom.xml
View file @
6cf2a8ed
...
...
@@ -41,7 +41,7 @@
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-dependencies
</artifactId>
<version>
2.
1.18
.RELEASE
</version>
<version>
2.
2.12
.RELEASE
</version>
<type>
pom
</type>
<scope>
import
</scope>
</dependency>
...
...
ruoyi-common/src/main/java/com/ruoyi/common/filter/RepeatableFilter.java
View file @
6cf2a8ed
...
...
@@ -29,8 +29,8 @@ public class RepeatableFilter implements Filter
throws
IOException
,
ServletException
{
ServletRequest
requestWrapper
=
null
;
if
(
request
instanceof
HttpServletRequest
&&
StringUtils
.
equalsAnyIgnoreCase
(
request
.
getContentType
(),
MediaType
.
APPLICATION_JSON_VALUE
,
MediaType
.
APPLICATION_JSON_UTF8
_VALUE
))
if
(
request
instanceof
HttpServletRequest
&&
StringUtils
.
equalsAnyIgnoreCase
(
request
.
getContentType
(),
MediaType
.
APPLICATION_JSON
_VALUE
))
{
requestWrapper
=
new
RepeatedlyRequestWrapper
((
HttpServletRequest
)
request
,
response
);
}
...
...
ruoyi-common/src/main/java/com/ruoyi/common/filter/XssHttpServletRequestWrapper.java
View file @
6cf2a8ed
...
...
@@ -99,7 +99,6 @@ public class XssHttpServletRequestWrapper extends HttpServletRequestWrapper
public
boolean
isJsonRequest
()
{
String
header
=
super
.
getHeader
(
HttpHeaders
.
CONTENT_TYPE
);
return
MediaType
.
APPLICATION_JSON_VALUE
.
equalsIgnoreCase
(
header
)
||
MediaType
.
APPLICATION_JSON_UTF8_VALUE
.
equalsIgnoreCase
(
header
);
return
MediaType
.
APPLICATION_JSON_VALUE
.
equalsIgnoreCase
(
header
);
}
}
\ No newline at end of file
ruoyi-framework/src/main/java/com/ruoyi/framework/config/RedisConfig.java
View file @
6cf2a8ed
...
...
@@ -8,8 +8,10 @@ import org.springframework.data.redis.connection.RedisConnectionFactory;
import
org.springframework.data.redis.core.RedisTemplate
;
import
org.springframework.data.redis.serializer.StringRedisSerializer
;
import
com.fasterxml.jackson.annotation.JsonAutoDetect
;
import
com.fasterxml.jackson.annotation.JsonTypeInfo
;
import
com.fasterxml.jackson.annotation.PropertyAccessor
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
com.fasterxml.jackson.databind.jsontype.impl.LaissezFaireSubTypeValidator
;
/**
* redis配置
...
...
@@ -31,7 +33,7 @@ public class RedisConfig extends CachingConfigurerSupport
ObjectMapper
mapper
=
new
ObjectMapper
();
mapper
.
setVisibility
(
PropertyAccessor
.
ALL
,
JsonAutoDetect
.
Visibility
.
ANY
);
mapper
.
enableDefaultTyping
(
ObjectMapper
.
DefaultTyping
.
NON_FINAL
);
mapper
.
activateDefaultTyping
(
LaissezFaireSubTypeValidator
.
instance
,
ObjectMapper
.
DefaultTyping
.
NON_FINAL
,
JsonTypeInfo
.
As
.
PROPERTY
);
serializer
.
setObjectMapper
(
mapper
);
template
.
setValueSerializer
(
serializer
);
...
...
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