Appearance
服务名称、端口与健康检查总表
本表基于 muotai-backend/pom.xml(当前版本 5.8.0,Spring Boot 3.4.5 / Spring Cloud 2024.0.0 / Java 21)、各模块 src/main/resources/application.yml、Dockerfile 与启动类 @EnableOpenApi 注解静态核对整理。它代表源码默认基线,而非某一线上环境的实时服务目录;每个服务的 Controller 与 SQL 证据见 后端服务源码证据表。
全部微服务与端口交互速查
| 服务模块 | 分类 | YAML 默认端口 | Dockerfile EXPOSE | 网关 / OpenAPI 前缀 | 健康检查与核心特征 |
|---|---|---|---|---|---|
| muotai-register | 平台基础 | 8848(Compose) | — | — | Nacos 3.1.0 注册与配置中心;Compose 探测 http://localhost:8848 |
| muotai-gateway | 平台基础 | 9999 | 9999 | 聚合入口 | /actuator/health;McpApiKeyGlobalFilter(5) + MuotaiRequestGlobalFilter(10) |
| muotai-auth | 平台基础 | 3000 | 3000 | /auth(路由约定) | /actuator/health;OAuth2 授权服务器,未标注 @EnableOpenApi |
| muotai-upms | 平台基础 | 4000 | 4000(待确认) | /admin | /actuator/health;@EnableOpenApi("admin"),dev Compose 曾写 4011 |
| muotai-common | 公共组件 | 无独立进程 | — | — | 多模块公共基础库(坐标 com.aroundix:muotai-common-*,原 pigx-common) |
| muotai-boot | 单体模式 | 8080 | 9999(与 YAML 差异) | /admin(isMicro=false) | /actuator/health;不在根 POM <modules> 中,供轻量化单体启动 |
| muotai-ai | AI 与数据 | 6062 | 6060(与 YAML 差异) | /ai | /actuator/health;@EnableOpenApi("ai"),prod Compose 曾探测 6060 |
| muotai-doc-space | AI 与数据 | 6061 | 6061 | /doc | /actuator/health;@EnableOpenApi("doc"),内置 MCP mcp-doc-server |
| muotai-spg | AI 与数据 | 9020 | — | /spg | /actuator/health;@EnableOpenApi("spg"),知识图谱与 KGDSL |
| muotai-light-app-data | AI 与数据 | 6073 | — | 未标注 @EnableOpenApi | /actuator/health;软著/文档审核等轻应用数据服务,内置 MCP mcp-light-server |
| muotai-vehicle-mcp | AI 与数据 | ${VEHICLE_MCP_PORT:6067} | — | 未标注 @EnableOpenApi | /actuator/health;内置 MCP mcp-vehicle-server,支持 Nacos MCP 注册开关 |
| muotai-audit | 业务域 | 6063 | 6063 | /audit | /actuator/health;@EnableOpenApi("audit"),内置 MCP mcp-audit-server |
| muotai-standard | 业务域 | 6064 | — | /standard | /actuator/health;@EnableOpenApi("standard"),部分接口返回独立 R<T>(code=200) |
| muotai-hmc | 业务域 | 6065 | — | /hmc | /actuator/health;@EnableOpenApi("hmc"),内置 MCP mcp-hmc-serverv1,含 WS /ws/situation-realtime |
| muotai-expert | 业务域 | 6066 | 6066 | /expert | /actuator/health;@EnableOpenApi("expert"),评标专家工单与合规配额 |
| muotai-accounting-data | 业务域 | 6070 | 6062(与 YAML 差异) | /accounting | /actuator/health;@EnableOpenApi("accounting"),财务报表与凭证数据 |
| muotai-app-mbti | 业务域 | 7061 | 7060(与 YAML 差异) | /mbti | /actuator/health;@EnableOpenApi("mbti"),ToC / MBTI 业务 |
| muotai-wflow | 业务域 | 7062 | — | /wflow | /actuator/health;@EnableOpenApi("wflow"),工作流引擎(响应为 Rsp<T> code=200) |
| muotai-pay | 商业化 | 5010 | — | /pay | /actuator/health;@EnableOpenApi("pay"),支付渠道与外部支付创建 |
| muotai-billing | 商业化 | 5020 | 6060(与 YAML 差异) | /billing | /actuator/health;@EnableOpenApi("billing"),订单、墨豆与存储账本 |
| muotai-growth | 商业化 | 5021 | 5021 | /growth | /actuator/health;@EnableOpenApi("growth"),邀请裂变与增长统计 |
端口分组速览(供站内检索)
- 平台与接入层:
muotai-register(8848)、muotai-gateway(9999)、muotai-auth(3000)、muotai-upms(4000)、muotai-boot(单体8080)、muotai-common(公共基础库,无端口)。 - AI、文档与知识层:
muotai-doc-space(6061)、muotai-ai(6062)、muotai-vehicle-mcp(${VEHICLE_MCP_PORT:6067})、muotai-light-app-data(6073)、muotai-spg(9020)。 - 垂直业务域:
muotai-audit(6063)、muotai-standard(6064)、muotai-hmc(6065)、muotai-expert(6066)、muotai-accounting-data(6070)、muotai-app-mbti(7061)、muotai-wflow(7062)。 - 商业化与增长:
muotai-pay(5010)、muotai-billing(5020)、muotai-growth(5021)。
内置 MCP Server 模块清单
对照各模块 application.yml,目前共有 5 个服务声明了 Spring AI MCP Server:
| 服务模块 | 默认端口 | MCP Server 名称 | 说明 |
|---|---|---|---|
muotai-doc-space-biz | 6061 | mcp-doc-server | 文档空间能力通过 MCP 暴露 |
muotai-audit-biz | 6063 | mcp-audit-server | 审计数据与控制点能力通过 MCP 暴露 |
muotai-hmc-biz | 6065 | mcp-hmc-serverv1 | HMC 协同与设备能力通过 MCP 暴露 |
muotai-vehicle-mcp-biz | ${VEHICLE_MCP_PORT:6067} | mcp-vehicle-server | 车辆领域 MCP 服务,注册受 VEHICLE_MCP_NACOS_REGISTER_ENABLED 控制 |
muotai-light-app-data-biz | 6073 | mcp-light-server | 轻应用数据服务 MCP 暴露 |
经由 Gateway 暴露给外部客户端的 /mcp 路径统一受 McpApiKeyGlobalFilter 保护,需携带 api_key=sk-...,详见 认证与响应。
端口差异与健康检查注意事项
严禁直接假设容器监听端口等于 Dockerfile EXPOSE
源码扫描发现多处 application.yml 默认端口与 Dockerfile / Compose 探针不一致,例如:
muotai-ai:YAML 默认6062,DockerfileEXPOSE 6060,docker-compose-prod.yml探测6060;muotai-accounting-data:YAML 默认6070,DockerfileEXPOSE 6062;muotai-billing:YAML 默认5020,DockerfileEXPOSE 6060;muotai-app-mbti:YAML 默认7061,DockerfileEXPOSE 7060;muotai-boot:YAML 默认8080,DockerfileEXPOSE 9999。
所有差异与待关闭条件集中登记在 当前实现与历史配置差异 与 Compose 核对。
关于健康检查路径 /actuator/health:
- 根
pom.xml已统一引入spring-boot-starter-actuator与spring-boot-admin-starter-client,业务微服务普遍具备/actuator/health端点。 - 该端点是否对外开放、是否纳入数据库连接/Redis/Nacos 就绪检查,受目标环境 Nacos
management.endpoints.web.exposure.include与management.endpoint.health.*配置影响,上线前必须在目标实例上用curl -sf http://<host>:<port>/actuator/health实测确认。