Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
B
basic-api-boot
概览
概览
详情
活动
周期分析
版本库
存储库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Basic
basic-api-boot
Commits
5d57c95e
提交
5d57c95e
authored
1月 19, 2026
作者:
方治民
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
chore: upgrade deps (SpringBoot v4.0.1) in progress ...
上级
753f8008
隐藏空白字符变更
内嵌
并排
正在显示
15 个修改的文件
包含
53 行增加
和
53 行删除
+53
-53
.gitattributes
.gitattributes
+1
-0
build.gradle
build.gradle
+18
-8
gradle-wrapper.jar
gradle/wrapper/gradle-wrapper.jar
+0
-0
gradle-wrapper.properties
gradle/wrapper/gradle-wrapper.properties
+1
-1
gradlew
gradlew
+4
-8
gradlew.bat
gradlew.bat
+1
-2
build.gradle
modules/common/core/build.gradle
+4
-4
CacheRequestContentFilter.java
...a/com/yiring/common/filter/CacheRequestContentFilter.java
+1
-1
SnowflakeIdGeneratorAccomplish.java
...ring/common/snowflake/SnowflakeIdGeneratorAccomplish.java
+0
-9
build.gradle
modules/common/job/build.gradle
+2
-1
build.gradle
modules/common/minio/build.gradle
+1
-1
RedisConfig.java
...s/src/main/java/com/yiring/common/config/RedisConfig.java
+6
-4
build.gradle
modules/common/util/build.gradle
+2
-2
MappingSerialize.java
...main/java/com/yiring/common/jackson/MappingSerialize.java
+1
-1
ObjectMappingSerializer.java
...va/com/yiring/common/jackson/ObjectMappingSerializer.java
+11
-11
没有找到文件。
.gitattributes
浏览文件 @
5d57c95e
# public/* linguist-vendored
/gradlew text eol=lf
*.bat text eol=crlf
*.jar binary
* text=auto eol=lf
build.gradle
浏览文件 @
5d57c95e
...
...
@@ -2,8 +2,9 @@ plugins {
id
'java'
id
'java-library'
// https://start.spring.io
id
'org.springframework.boot'
version
'3.5.9'
id
'org.graalvm.buildtools.native'
version
'0.10.6'
id
'org.springframework.boot'
version
'4.0.1'
id
'org.graalvm.buildtools.native'
version
'0.11.3'
id
'org.hibernate.orm'
version
'7.2.0.Final'
// https://plugins.gradle.org/plugin/io.spring.dependency-management
id
'io.spring.dependency-management'
version
'1.1.7'
// https://plugins.gradle.org/plugin/com.diffplug.spotless
...
...
@@ -25,7 +26,7 @@ ext {
// SpringCloud
// https://start.spring.io/
springCloudVersion
=
'2025.
0.1
'
springCloudVersion
=
'2025.
1.0
'
// SpringBootAdmin
// https://central.sonatype.com/artifact/de.codecentric/spring-boot-admin-starter-server
...
...
@@ -47,13 +48,15 @@ ext {
// https://central.sonatype.com/artifact/com.alibaba.fastjson2/fastjson2
fastJsonVersion
=
'2.0.60'
// https://central.sonatype.com/artifact/com.xuxueli/xxl-job-core
xxlJobVersion
=
'3.
2.0
'
xxlJobVersion
=
'3.
3.1
'
// https://central.sonatype.com/artifact/io.minio/minio
minioVersion
=
'8.6.0'
// https://central.sonatype.com/artifact/io.hypersistence/hypersistence-utils-hibernate-
63
// https://central.sonatype.com/artifact/io.hypersistence/hypersistence-utils-hibernate-
71
hibernateTypesVersion
=
'3.14.1'
// https://central.sonatype.com/artifact/org.hibernate.orm/hibernate-spatial
hibernateSpatialVersion
=
'7.2.0.Final'
// https://central.sonatype.com/artifact/app.tozzi/jpa-search-helper
jpaSearchHelperVersion
=
'3.6.2'
// https://central.sonatype.com/artifact/org.locationtech.jts/jts-core
jtsVersion
=
'1.20.0'
// https://mvnrepository.com/artifact/org.n52.jackson/jackson-datatype-jts
...
...
@@ -67,7 +70,7 @@ ext {
// https://central.sonatype.com/artifact/org.lionsoul/ip2region
ip2regionVersion
=
'3.3.2'
// https://central.sonatype.com/artifact/com.github.piomin/loki-logging-spring-boot-starter
lokiLoggingVersion
=
'2.
0.3
'
lokiLoggingVersion
=
'2.
2.1
'
// https://central.sonatype.com/artifact/com.github.ulisesbocchio/jasypt-spring-boot-starter
jasyptVersion
=
'4.0.3'
// https://central.sonatype.com/artifact/net.bramp.ffmpeg/ffmpeg
...
...
@@ -77,7 +80,7 @@ ext {
java
{
toolchain
{
languageVersion
=
JavaLanguageVersion
.
of
(
17
)
languageVersion
=
JavaLanguageVersion
.
of
(
21
)
}
}
...
...
@@ -106,9 +109,10 @@ subprojects {
}
dependencies
{
implementation
'org.springframework.
boot:spring-boot-starter
'
implementation
'org.springframework.
cloud:spring-cloud-starter-config
'
testImplementation
'org.springframework.boot:spring-boot-starter-test'
testRuntimeOnly
'org.junit.platform:junit-platform-launcher'
developmentOnly
'org.springframework.boot:spring-boot-devtools'
compileOnly
'org.projectlombok:lombok'
annotationProcessor
'org.projectlombok:lombok'
annotationProcessor
'org.springframework.boot:spring-boot-configuration-processor'
...
...
@@ -122,6 +126,12 @@ subprojects {
}
}
hibernate
{
enhancement
{
enableAssociationManagement
=
true
}
}
[
compileJava
,
compileTestJava
,
javadoc
]*.
options
*.
encoding
=
'UTF-8'
tasks
.
withType
(
JavaCompile
).
tap
{
...
...
gradle/wrapper/gradle-wrapper.jar
浏览文件 @
5d57c95e
No preview for this file type
gradle/wrapper/gradle-wrapper.properties
浏览文件 @
5d57c95e
distributionBase
=
GRADLE_USER_HOME
distributionPath
=
wrapper/dists
distributionUrl
=
https
\:
//mirrors.aliyun.com/gradle/distributions/v
8.14.3/gradle-8.14.3
-bin.zip
distributionUrl
=
https
\:
//mirrors.aliyun.com/gradle/distributions/v
9.2.1/gradle-9.2.1
-bin.zip
networkTimeout
=
10000
validateDistributionUrl
=
true
zipStoreBase
=
GRADLE_USER_HOME
...
...
gradlew
浏览文件 @
5d57c95e
#!/bin/sh
#
# Copyright © 2015
-2021
the original authors.
# Copyright © 2015 the original authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
...
...
@@ -86,8 +86,7 @@ done
# shellcheck disable=SC2034
APP_BASE_NAME
=
${
0
##*/
}
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME
=
$(
cd
-P
"
${
APP_HOME
:-
./
}
"
>
/dev/null
&&
printf
'%s
'
"
$PWD
"
)
||
exit
APP_HOME
=
$(
cd
-P
"
${
APP_HOME
:-
./
}
"
>
/dev/null
&&
printf
'%s\n'
"
$PWD
"
)
||
exit
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD
=
maximum
...
...
@@ -115,7 +114,6 @@ case "$( uname )" in #(
NONSTOP
*
)
nonstop
=
true
;;
esac
CLASSPATH
=
$APP_HOME
/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
...
...
@@ -173,7 +171,6 @@ fi
# For Cygwin or MSYS, switch paths to Windows format before running java
if
"
$cygwin
"
||
"
$msys
"
;
then
APP_HOME
=
$(
cygpath
--path
--mixed
"
$APP_HOME
"
)
CLASSPATH
=
$(
cygpath
--path
--mixed
"
$CLASSPATH
"
)
JAVACMD
=
$(
cygpath
--unix
"
$JAVACMD
"
)
...
...
@@ -206,15 +203,14 @@ fi
DEFAULT_JVM_OPTS
=
'"-Xmx64m" "-Xms64m"'
# Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS,
JAVA_OPTS,
and optsEnvironmentVar are not allowed to contain shell fragments,
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.
set
--
\
"-Dorg.gradle.appname=
$APP_BASE_NAME
"
\
-classpath
"
$CLASSPATH
"
\
org.gradle.wrapper.GradleWrapperMain
\
-jar
"
$APP_HOME
/gradle/wrapper/gradle-wrapper.jar"
\
"
$@
"
# Stop when "xargs" is not available.
...
...
gradlew.bat
浏览文件 @
5d57c95e
...
...
@@ -70,11 +70,10 @@ goto fail
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -
classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain
%*
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -
jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar"
%*
:end
@rem End local scope for the variables with windows NT shell
...
...
modules/common/core/build.gradle
浏览文件 @
5d57c95e
...
...
@@ -4,8 +4,8 @@ dependencies {
implementation
project
(
":modules:common:redis"
)
implementation
project
(
":modules:common:doc"
)
implementation
'org.springframework.boot:spring-boot-starter-a
op
'
implementation
'org.springframework.boot:spring-boot-starter-web'
implementation
'org.springframework.boot:spring-boot-starter-a
spectj
'
implementation
'org.springframework.boot:spring-boot-starter-web
mvc
'
implementation
'org.springframework.boot:spring-boot-starter-data-jpa'
implementation
'org.springframework.boot:spring-boot-starter-data-redis'
implementation
'org.springframework.boot:spring-boot-starter-validation'
...
...
@@ -18,8 +18,8 @@ dependencies {
implementation
"com.alibaba.fastjson2:fastjson2:${fastJsonVersion}"
// https://github.com/vladmihalcea/hypersistence-utils
// hypersistence-utils-hibernate-
63
implementation
"io.hypersistence:hypersistence-utils-hibernate-
63
:${hibernateTypesVersion}"
// hypersistence-utils-hibernate-
71
implementation
"io.hypersistence:hypersistence-utils-hibernate-
71
:${hibernateTypesVersion}"
// JTS 几何对象操作库
implementation
"org.locationtech.jts:jts-core:${jtsVersion}"
...
...
modules/common/core/src/main/java/com/yiring/common/filter/CacheRequestContentFilter.java
浏览文件 @
5d57c95e
...
...
@@ -22,6 +22,6 @@ public class CacheRequestContentFilter extends OncePerRequestFilter {
@NotNull
HttpServletResponse
response
,
FilterChain
chain
)
throws
ServletException
,
IOException
{
chain
.
doFilter
(
new
ContentCachingRequestWrapper
(
request
),
response
);
chain
.
doFilter
(
new
ContentCachingRequestWrapper
(
request
,
-
1
),
response
);
}
}
modules/common/core/src/main/java/com/yiring/common/snowflake/SnowflakeIdGeneratorAccomplish.java
浏览文件 @
5d57c95e
...
...
@@ -16,7 +16,6 @@ import org.hibernate.generator.BeforeExecutionGenerator;
import
org.hibernate.generator.EventType
;
import
org.hibernate.generator.EventTypeSets
;
import
org.hibernate.generator.GeneratorCreationContext
;
import
org.hibernate.id.factory.spi.CustomIdGeneratorCreationContext
;
/**
* @author Jim
...
...
@@ -44,14 +43,6 @@ public class SnowflakeIdGeneratorAccomplish implements BeforeExecutionGenerator
public
SnowflakeIdGeneratorAccomplish
(
SnowflakeIdGenerator
config
,
Member
idMember
,
CustomIdGeneratorCreationContext
creationContext
)
{
this
(
config
,
idMember
);
}
public
SnowflakeIdGeneratorAccomplish
(
SnowflakeIdGenerator
config
,
Member
member
,
GeneratorCreationContext
creationContext
)
{
...
...
modules/common/job/build.gradle
浏览文件 @
5d57c95e
...
...
@@ -5,7 +5,8 @@ plugins {
dependencies
{
implementation
project
(
":modules:common:core"
)
implementation
project
(
":modules:common:i18n"
)
implementation
'org.springframework.boot:spring-boot-starter-aop'
implementation
'org.springframework.boot:spring-boot-starter-aspectj'
// xxl-job
api
"com.xuxueli:xxl-job-core:${xxlJobVersion}"
...
...
modules/common/minio/build.gradle
浏览文件 @
5d57c95e
...
...
@@ -7,7 +7,7 @@ dependencies {
implementation
project
(
":modules:common:util"
)
implementation
project
(
":modules:common:doc"
)
implementation
'org.springframework.boot:spring-boot-starter-web'
implementation
'org.springframework.boot:spring-boot-starter-web
mvc
'
implementation
'org.springframework.boot:spring-boot-starter-validation'
// minio
...
...
modules/common/redis/src/main/java/com/yiring/common/config/RedisConfig.java
浏览文件 @
5d57c95e
/* (C) 2022 YiRing, Inc. */
package
com
.
yiring
.
common
.
config
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
java.time.Duration
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.cache.annotation.EnableCaching
;
...
...
@@ -11,9 +10,10 @@ import org.springframework.data.redis.cache.RedisCacheConfiguration;
import
org.springframework.data.redis.cache.RedisCacheManager
;
import
org.springframework.data.redis.connection.RedisConnectionFactory
;
import
org.springframework.data.redis.core.RedisTemplate
;
import
org.springframework.data.redis.serializer.GenericJackson
2
JsonRedisSerializer
;
import
org.springframework.data.redis.serializer.GenericJacksonJsonRedisSerializer
;
import
org.springframework.data.redis.serializer.RedisSerializationContext
;
import
org.springframework.data.redis.serializer.StringRedisSerializer
;
import
tools.jackson.databind.ObjectMapper
;
/**
* Redis Config
...
...
@@ -36,7 +36,7 @@ public class RedisConfig {
StringRedisSerializer
stringRedisSerializer
=
new
StringRedisSerializer
();
redisTemplate
.
setKeySerializer
(
stringRedisSerializer
);
redisTemplate
.
setHashKeySerializer
(
stringRedisSerializer
);
redisTemplate
.
setDefaultSerializer
(
new
GenericJackson
2
JsonRedisSerializer
(
objectMapper
));
redisTemplate
.
setDefaultSerializer
(
new
GenericJacksonJsonRedisSerializer
(
objectMapper
));
redisTemplate
.
setEnableTransactionSupport
(
false
);
redisTemplate
.
setConnectionFactory
(
factory
);
redisTemplate
.
afterPropertiesSet
();
...
...
@@ -50,7 +50,9 @@ public class RedisConfig {
.
entryTtl
(
Duration
.
ofMinutes
(
5
))
.
serializeKeysWith
(
RedisSerializationContext
.
SerializationPair
.
fromSerializer
(
new
StringRedisSerializer
()))
.
serializeValuesWith
(
RedisSerializationContext
.
SerializationPair
.
fromSerializer
(
new
GenericJackson2JsonRedisSerializer
())
RedisSerializationContext
.
SerializationPair
.
fromSerializer
(
new
GenericJacksonJsonRedisSerializer
(
objectMapper
)
)
)
.
disableCachingNullValues
();
...
...
modules/common/util/build.gradle
浏览文件 @
5d57c95e
...
...
@@ -3,8 +3,8 @@ plugins {
}
dependencies
{
implementation
'org.springframework.boot:spring-boot-starter-a
op
'
implementation
'org.springframework.boot:spring-boot-starter-web'
implementation
'org.springframework.boot:spring-boot-starter-a
spectj
'
implementation
'org.springframework.boot:spring-boot-starter-web
mvc
'
implementation
'org.springframework.boot:spring-boot-starter-validation'
// Spring Retry
...
...
modules/common/util/src/main/java/com/yiring/common/jackson/MappingSerialize.java
浏览文件 @
5d57c95e
...
...
@@ -2,8 +2,8 @@
package
com
.
yiring
.
common
.
jackson
;
import
com.fasterxml.jackson.annotation.JacksonAnnotationsInside
;
import
com.fasterxml.jackson.databind.annotation.JsonSerialize
;
import
java.lang.annotation.*
;
import
tools.jackson.databind.annotation.JsonSerialize
;
/**
* Jackson Mapping 序列化
...
...
modules/common/util/src/main/java/com/yiring/common/jackson/ObjectMappingSerializer.java
浏览文件 @
5d57c95e
/* (C) 2021 YiRing, Inc. */
package
com
.
yiring
.
common
.
jackson
;
import
com.fasterxml.jackson.core.JsonGenerator
;
import
com.fasterxml.jackson.databind.BeanProperty
;
import
com.fasterxml.jackson.databind.JsonSerializer
;
import
com.fasterxml.jackson.databind.SerializerProvider
;
import
com.fasterxml.jackson.databind.ser.ContextualSerializer
;
import
com.fasterxml.jackson.databind.ser.std.StdSerializer
;
import
java.io.IOException
;
import
java.io.Serial
;
import
java.io.Serializable
;
import
java.util.HashMap
;
import
java.util.Map
;
import
java.util.Objects
;
import
tools.jackson.core.JacksonException
;
import
tools.jackson.core.JsonGenerator
;
import
tools.jackson.databind.BeanProperty
;
import
tools.jackson.databind.SerializationContext
;
import
tools.jackson.databind.ValueSerializer
;
import
tools.jackson.databind.ser.std.StdSerializer
;
/**
* Mapping 序列化
...
...
@@ -20,7 +20,7 @@ import java.util.Objects;
* @version 0.1
* 2021/10/15 18:11
*/
public
class
ObjectMappingSerializer
extends
StdSerializer
<
Object
>
implements
ContextualSerializer
{
public
class
ObjectMappingSerializer
extends
StdSerializer
<
Object
>
implements
Serializable
{
@Serial
private
static
final
long
serialVersionUID
=
-
1924851196524453827L
;
...
...
@@ -36,7 +36,7 @@ public class ObjectMappingSerializer extends StdSerializer<Object> implements Co
}
@Override
public
JsonSerializer
<?>
createContextual
(
SerializerProvider
prov
,
BeanProperty
property
)
{
public
ValueSerializer
<?>
createContextual
(
SerializationContext
ctx
,
BeanProperty
property
)
{
MappingSerialize
mappingSerialize
=
property
.
getAnnotation
(
MappingSerialize
.
class
);
String
mapping
=
mappingSerialize
.
mapping
();
...
...
@@ -55,10 +55,10 @@ public class ObjectMappingSerializer extends StdSerializer<Object> implements Co
}
@Override
public
void
serialize
(
Object
value
,
JsonGenerator
gen
,
Serializ
erProvider
provider
)
throws
IO
Exception
{
public
void
serialize
(
Object
value
,
JsonGenerator
gen
,
Serializ
ationContext
provider
)
throws
Jackson
Exception
{
String
text
=
mapping
.
get
(
Objects
.
toString
(
value
));
if
(
text
==
null
||
text
.
isEmpty
())
{
gen
.
writeObject
(
value
);
gen
.
writeObject
Ref
(
value
);
}
else
{
gen
.
writeString
(
text
);
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论