1. 替换原始 code 签名

2. 服务与模块生成器,支持指定起始端口批量端口分配

(cherry picked from commit e99da38fd4)
This commit is contained in:
chenbowen
2025-09-02 10:15:16 +08:00
committed by chenbowen
parent 9929ae8a39
commit 1e1216c150
778 changed files with 876 additions and 801 deletions

View File

@@ -15,7 +15,7 @@ import reactor.core.publisher.Mono;
/**
* 跨域 Filter
*
* @author 芋道源码
* @author ZT
*/
@Component
public class CorsFilter implements WebFilter {

View File

@@ -19,7 +19,7 @@ import java.util.stream.Collectors;
*
* 参考文档:<a href="https://blog.csdn.net/zimou5581/article/details/90043178" />
*
* @author 芋道源码
* @author ZT
*/
@Component
public class CorsResponseHeaderFilter implements GlobalFilter, Ordered {

View File

@@ -28,7 +28,7 @@ import java.util.List;
* 注意,考虑到实现的简易,它的权重是使用 Nacos 的 nacos.weight所以随机 + 权重也是基于 {@link NacosBalancer} 筛选。
* 也就是说,如果你不使用 Nacos 作为注册中心,需要微调一下筛选的实现逻辑
*
* @author 芋道源码
* @author ZT
*/
@RequiredArgsConstructor
@Slf4j

View File

@@ -33,7 +33,7 @@ import static org.springframework.cloud.gateway.support.ServerWebExchangeUtils.*
* 1. https://www.jianshu.com/p/6db15bc0be8f
* 2. https://cloud.tencent.com/developer/article/1620795
*
* @author 芋道源码
* @author ZT
*/
@Component
@AllArgsConstructor

View File

@@ -52,7 +52,7 @@ import static cn.hutool.core.date.DatePattern.NORM_DATETIME_MS_FORMATTER;
*
* TODO 芋艿:如果网关执行异常,不会记录访问日志,后续研究下 https://github.com/Silvmike/webflux-demo/blob/master/tests/src/test/java/ru/hardcoders/demo/webflux/web_handler/filters/logging
*
* @author 芋道源码
* @author ZT
*/
@Slf4j
@Component

View File

@@ -11,7 +11,7 @@ import java.util.Map;
*
* copy from yudao-spring-boot-starter-security 的 LoginUser 类
*
* @author 芋道源码
* @author ZT
*/
@Data
public class LoginUser {

View File

@@ -33,7 +33,7 @@ import static cn.iocoder.yudao.framework.common.util.cache.CacheUtils.buildAsync
* 1. 验证通过时,将 userId、userType、tenantId 通过 Header 转发给服务
* 2. 验证不通过,还是会转发给服务。因为,接口是否需要登录的校验,还是交给服务自身处理
*
* @author 芋道源码
* @author ZT
*/
@Component
public class TokenAuthenticationFilter implements GlobalFilter, Ordered {

View File

@@ -20,7 +20,7 @@ import static cn.iocoder.yudao.framework.common.exception.enums.GlobalErrorCodeC
*
* 在功能上,和 yudao-spring-boot-starter-web 的 GlobalExceptionHandler 类是一致的
*
* @author 芋道源码
* @author ZT
*/
@Component
@Order(-1) // 保证优先级高于默认的 Spring Cloud Gateway 的 ErrorWebExceptionHandler 实现

View File

@@ -5,6 +5,6 @@
*
* 使用方式:在 Nacos 修改 DataId 为 gateway-server.yaml 的配置,修改 spring.cloud.gateway.routes 配置项
*
* @author 芋道源码
* @author ZT
*/
package cn.iocoder.yudao.gateway.route.dynamic;

View File

@@ -11,7 +11,7 @@ import java.util.concurrent.TimeUnit;
/**
* 项目启动成功后,提供文档相关的地址
*
* @author 芋道源码
* @author ZT
*/
@Component
@Slf4j

View File

@@ -13,7 +13,7 @@ import java.util.Objects;
*
* copy from yudao-spring-boot-starter-env 的 EnvUtils 类
*
* @author 芋道源码
* @author ZT
*/
public class EnvUtils {

View File

@@ -16,7 +16,7 @@ import java.nio.charset.StandardCharsets;
*
* copy from yudao-spring-boot-starter-security 的 SecurityFrameworkUtils 类
*
* @author 芋道源码
* @author ZT
*/
@Slf4j
public class SecurityFrameworkUtils {

View File

@@ -21,7 +21,7 @@ import reactor.core.publisher.Mono;
*
* copy from yudao-spring-boot-starter-web 的 WebFrameworkUtils 类
*
* @author 芋道源码
* @author ZT
*/
@Slf4j
public class WebFrameworkUtils {

View File

@@ -20,7 +20,7 @@ import static java.io.File.separator;
* <p>
* 通过修改 groupIdNew、artifactIdNew、projectBaseDirNew 三个变量
*
* @author 芋道源码
* @author ZT
*/
@Slf4j
public class ProjectReactor {