build: continew-starter 2.12.2 => 2.13.0

1.引入 continew-starter-validation(从 core 拆分)、sa-token-sign(从 sa-token-core 拆分并调整了部分 API)
2.Starter import 包路径调整
- EasyExcel 替换为 FastExcel:com.alibaba.excel(EasyExcel) => cn.idev.excel(FastExcel)
- top.continew.starter.file.excel => top.continew.starter.excel
- top.continew.starter.core.validation.constraints => top.continew.starter.validation.constraints
- top.continew.starter.core.validation.ValidationUtils、CheckUtils、Validator => top.continew.starter.core.util.validation
- cn.dev33.satoken.sign => cn.dev33.satoken.sign.template
- top.continew.starter.core.autoconfigure.project => top.continew.starter.core.autoconfigure.application
- top.continew.starter.data.core、top.continew.starter.data.mp => top.continew.starter.data
- top.continew.starter.data.mp.base.BaseMapper => top.continew.starter.data.mapper.BaseMapper
2.Starter 基础类命名调整
CRUD:AbstractBaseController => AbstractCrudController,BaseService => CrudService,BaseServiceImpl => CrudServiceImpl
Core:ProjectProperties(项目配置,project.xxx) => ApplicationProperties(应用配置更为贴切,且变量 application.xx 可以和 Maven 变量显著区分开)
3.groupId 调整:top.continew.starter、top.continew.admin(避免部分童鞋全局替换包名时出现把 starter 也一起替换了!)
4.Admin import 包路径调整:BaseController、BaseDO等 => common.base
5.新增 BaseService、BaseServiceImpl 替代 Starter 原 BaseXxx,方便用户根据项目实际需要重写或新增全局通用接口、方法
6.snail-job server 数据库脚本更新至 v1.5.0
7.Valid 及 Validated 使用梳理(CrudService 支持通过在实现类添加 Validated 注解来实现 Service 层基础校验)
This commit is contained in:
2025-07-05 21:33:45 +08:00
parent efb65c21a1
commit 2138bee42c
184 changed files with 714 additions and 575 deletions

View File

@@ -29,12 +29,13 @@ import org.dromara.x.file.storage.spring.EnableFileStorage;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringBootVersion;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.web.ServerProperties;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import top.continew.starter.core.autoconfigure.project.ProjectProperties;
import top.continew.starter.core.autoconfigure.application.ApplicationProperties;
import top.continew.starter.extension.crud.annotation.EnableCrudRestController;
import top.continew.starter.web.annotation.EnableGlobalResponse;
import top.continew.starter.web.model.R;
@@ -56,7 +57,7 @@ import top.continew.starter.web.model.R;
@RequiredArgsConstructor
public class ContiNewAdminApplication implements ApplicationRunner {
private final ProjectProperties projectProperties;
private final ApplicationProperties applicationProperties;
private final ServerProperties serverProperties;
public static void main(String[] args) {
@@ -67,7 +68,7 @@ public class ContiNewAdminApplication implements ApplicationRunner {
@SaIgnore
@GetMapping("/")
public R index() {
return R.ok(projectProperties);
return R.ok(applicationProperties);
}
@Override
@@ -76,18 +77,19 @@ public class ContiNewAdminApplication implements ApplicationRunner {
Integer port = serverProperties.getPort();
String contextPath = serverProperties.getServlet().getContextPath();
String baseUrl = URLUtil.normalize("%s:%s%s".formatted(hostAddress, port, contextPath));
log.info("----------------------------------------------");
log.info("{} service started successfully.", projectProperties.getName());
log.info("Profile: {}", SpringUtil.getProperty("spring.profiles.active"));
log.info("项目版本: v{} (ContiNew Starter: v{})", projectProperties.getVersion(), SpringUtil
.getProperty("project.starter"));
log.info("API 地址: {}", baseUrl);
log.info("-----------------------------------------------------");
log.info("{} server started successfully.", applicationProperties.getName());
log.info("ContiNew Starter: v{} (Spring Boot: v{})", SpringUtil
.getProperty("application.starter"), SpringBootVersion.getVersion());
log.info("当前版本: v{} (Profile: {})", applicationProperties.getVersion(), SpringUtil
.getProperty("spring.profiles.active"));
log.info("服务地址: {}", baseUrl);
Knife4jProperties knife4jProperties = SpringUtil.getBean(Knife4jProperties.class);
if (!knife4jProperties.isProduction()) {
log.info("API 文档: {}/doc.html", baseUrl);
log.info("接口文档: {}/doc.html", baseUrl);
}
log.info("在线文档: https://continew.top");
log.info("常见问题: https://continew.top/admin/faq.html");
log.info("----------------------------------------------");
log.info("-----------------------------------------------------");
}
}