zizi c74aa7dab6 refactor(rename): yudao 命名空间整体改名 com.wanxiang.huijing(公司 Wanxiang / 项目 Huijing)
- 包根 cn.iocoder.yudao → com.wanxiang.huijing;业务 cn.wanxiang.game → com.wanxiang.huijing.game(统一单一命名空间)
- groupId cn.iocoder.cloud → com.wanxiang;artifactId + 模块目录 yudao-* → huijing-*(含 huijing-server/framework/gateway/dependencies)
- 类名 Yudao* → Huijing*(44 个);配置前缀 yudao.* → huijing.*(Tier A 标识符 + Tier B 配置)
- 排除不动:Flyway 迁移脚本(不可变历史,保 checksum)、上游归属 URL/LICENSE、DB 表名(真表 system_*/game_*,无 yudao_ 业务表)
- 范围:game-cloud + game-admin。范围外 contracts/docs/.agents 的 yudao 引用=文档漂移,后续单独清(Opus H4 判不阻断)

评审:Opus 对抗复审(逮 Flyway checksum Blocker→已修排除迁移);Codex 未同步交回。
本地验证:apply 幂等✓;范围内真代码残留 0(16 处 \bYudao 均在已排除迁移注释内)。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-15 13:05:48 +00:00

178 lines
9.1 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>com.wanxiang</groupId>
<artifactId>game-module-aigc</artifactId>
<version>${revision}</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>game-module-aigc-server</artifactId>
<packaging>jar</packaging>
<name>${project.artifactId}</name>
<description>
aigc 模块业务实现:controller(app/admin) / service / dal(DO·Mapper) / convert。
生成任务异步队列 + 状态机(轮询/取消/重试);Dify/MQ/LLM 仅对接点。
被 huijing-server 聚合启动(随单体一起加载,无需独立 bootstrap)。
</description>
<dependencies>
<!-- Spring Cloud 基础环境 -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-env</artifactId>
</dependency>
<!-- 本模块对外契约层 -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>game-module-aigc-api</artifactId>
<version>${revision}</version>
</dependency>
<!-- 回调落包链依赖 project 的 -api:createForPackage 建版本拿 versionId(跨模块只依赖对方 -api,禁依赖 -server,守门④;HJ-AGENT-LOOP-EXEC-001 §8.2) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>game-module-project-api</artifactId>
<version>${revision}</version>
</dependency>
<!-- 依赖 community 的 -api:P-NTF-02 生成完成后同进程 notify 站内信(Wave4 挂点1;事务提交后调 + try-catch 吞异常,禁依赖 -server) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>game-module-community-api</artifactId>
<version>${revision}</version>
</dependency>
<!-- 回调落包链依赖 runtime 的 -api:storeForVersion 建运行包行 + 写整包 manifest(跨模块只依赖对方 -api,禁依赖 -server,守门④;HJ-AGENT-LOOP-EXEC-001 §8.2) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>game-module-runtime-api</artifactId>
<version>${revision}</version>
</dependency>
<!-- 依赖 system 的 -api:直发生成入口校验创作者白名单(PlayerApi#validateCreator,2026-06-10 鉴权件 §6.3,拍板4 可信边界) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-module-system-api</artifactId>
<version>${revision}</version>
</dependency>
<!-- 业务组件:数据权限(创作者只见自己任务)+ 多租户(DO 继承 TenantBaseDO) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-biz-data-permission</artifactId>
</dependency>
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-biz-tenant</artifactId>
</dependency>
<!-- Web + 安全:@RestController / @PreAuthorize / 当前登录用户 -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-security</artifactId>
</dependency>
<!-- DB:MyBatis Plus(BaseMapperX / LambdaQueryWrapperX / BaseDO) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-mybatis</artifactId>
</dependency>
<!-- JSON Schema 校验(HJ-AGENT-LOOP-EXEC-002 §7 / §16-3 已批准):生成执行器按 contracts/templates/
clicker.schema.json 同源校验 LLM 直出 GameConfig(注入 prompt 的 schema 文本与服务端校验对象
字面同源,零逻辑分叉;替代手写校验防双源漂移)。运行时仅依赖 Jackson/slf4j,均已在 classpath。
版本由 huijing-dependencies 统一管理。 -->
<dependency>
<groupId>com.networknt</groupId>
<artifactId>json-schema-validator</artifactId>
</dependency>
<!-- 缓存 -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-redis</artifactId>
</dependency>
<!-- RPC 远程调用(跨模块互调,预留回写 project.game_version、对接 runtime/feed) -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-rpc</artifactId>
</dependency>
<!-- 测试 -->
<dependency>
<groupId>com.wanxiang</groupId>
<artifactId>huijing-spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<finalName>${project.artifactId}</finalName>
<plugins>
<!-- 契约资源构建期快照(HJ-AGENT-LOOP-EXEC-002 §6.1 方案 A):把 contracts 两文件复制进
classpath:wanxiang-contracts/——git contracts/ 仍是唯一事实源,jar 内只是构建时快照;
改 prompt = 改 contracts 原文件 + 升 version + 过四道闸 → 下次构建部署自动携带新版。
已知坑:maven 对不存在的 resource 目录静默跳过(不报错)——若未来拆独立仓致相对路径失效,
兜底 = 执行器启动自检(PromptResourceLoader:资源缺失自禁用 + log.error,永不带病认领)。 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<!-- 显式钉版本:消除 effective model 告警,并保证快照复制行为不随 Maven 发行版默认值漂移 -->
<version>3.3.1</version>
<executions>
<!-- 主 classpath 快照:执行器运行时读取(test classpath 含主输出目录,单测对拍同此快照) -->
<execution>
<id>copy-wanxiang-contracts</id>
<phase>generate-resources</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>${project.build.outputDirectory}/wanxiang-contracts</outputDirectory>
<resources>
<resource>
<!-- 仓库根 contracts/(aigc-server → game-module-aigc → game-cloud → 仓库根) -->
<directory>${project.basedir}/../../../contracts</directory>
<!-- HJ-MC-TPL-EXEC-001 §6.2:通配复制各模板 designer prompt + schema(clicker/merge/批② idle/tycoon),
一次性覆盖未来新模板,免每模板手改 pom(兑现「加文件即开模板」承诺)。
此前仅复制 clicker 两单文件,merge 两文件不会自动进 classpath → merge 自禁用,必须改通配。 -->
<includes>
<include>prompts/04-config/*.md</include>
<include>templates/*.schema.json</include>
</includes>
</resource>
</resources>
</configuration>
</execution>
<!-- 测试夹具快照(仅 test classpath,不入产物 jar):C1 spike 实测通过的 6 条 accepted
configs,供 GameConfigSchemaValidatorTest 全过断言(HJ-AGENT-LOOP-EXEC-002 §11) -->
<execution>
<id>copy-wanxiang-test-fixtures</id>
<phase>generate-test-resources</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>${project.build.testOutputDirectory}/wanxiang-test-fixtures</outputDirectory>
<resources>
<resource>
<directory>${project.basedir}/../../../docs/agent-specs/2026-06-09-generation-spike</directory>
<includes>
<include>accepted-configs.json</include>
</includes>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>